var QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg = { close:function(){var popup = document.getElementById('QualtricsPopup_SV_e9dKhJhAF4kXqKg');popup.parentNode.removeChild(popup);}, popup:function(width, height,animate_popup) { var customImage = false; var background = true; var docSize=QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.getWindowSize(); var docWidth=docSize[0]; var docHeight=docSize[1]; if(width > docWidth) width = docWidth; if(height > docHeight) height = docHeight; var surveyPopupWidth = 954; var surveyPopupHeight = 500; if(surveyPopupWidth > docWidth) surveyPopupWidth = docWidth; if(surveyPopupHeight > docHeight) surveyPopupHeight = docHeight; if(typeof(SV_e9dKhJhAF4kXqKg_ed) == 'undefined') SV_e9dKhJhAF4kXqKg_ed = ''; //popup styles //popup body var pbpadding = customImage?0:20; var closeX = (horizontal_offset+3); var closeY = (vertical_offset+3); pbHTML = SV_e9dKhJhAF4kXqKg_text+"

"+SV_e9dKhJhAF4kXqKg_link+""; var xfactor = 0.091837; var yfactor = 0.115384; var xmultiple = 1.225; var ymultiple = 1.3; var mhoff = ((xmultiple-1)*width)/2; var mvoff = ((ymultiple-1)*height)/2; var horizontal_offset = width*xfactor var vertical_offset = height*yfactor; var popup_frame = document.createElement('div'); popup_frame.style.position='absolute'; popup_frame.style.width=(customImage?(width*xmultiple):width)+'px'; popup_frame.style.height=(customImage?(height*ymultiple):height)+'px'; popup_frame.style.zIndex=20000; popup_frame.id='QualtricsPopup_SV_e9dKhJhAF4kXqKg'; if (background) { var drop_shadow = document.createElement('img'); drop_shadow.style.width='100%'; drop_shadow.style.height='100%'; drop_shadow.src="http://lds.qualtrics.com/SE//static/q-generic/.9414483/img/popup_shadow.png"; drop_shadow.style.position='relative'; drop_shadow.style.zIndex='20000'; drop_shadow = QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.fixPNG(drop_shadow,width,height); popup_frame.appendChild(drop_shadow); } var popup_x = document.createElement('img'); popup_x.style.width='13px'; popup_x.style.height='13px'; popup_x.src="http://lds.qualtrics.com/SE//static/q-generic/.9414483/img/popup_x.png"; popup_x.style.position='absolute'; popup_x.style.top=(customImage?((vertical_offset+3)+mhoff):(vertical_offset+3))+'px'; popup_x.style.right=(customImage?((horizontal_offset+3)+mvoff):(horizontal_offset+3))+'px'; popup_x.style.cursor='pointer'; popup_x.style.zIndex='20001'; popup_x.onclick=function(){var popup = document.getElementById('QualtricsPopup_SV_e9dKhJhAF4kXqKg');popup.parentNode.removeChild(popup);}; var popup_body = document.createElement('div'); popup_body.style.position='absolute'; if (background) { popup_body.style.top=(customImage?mvoff:vertical_offset)+'px'; popup_body.style.left=(customImage?mhoff:horizontal_offset)+'px'; if (!customImage) popup_body.style.width=(width-2*horizontal_offset-2*pbpadding)+'px'; if (!customImage) popup_body.style.height=(height-2*vertical_offset-2*pbpadding)+'px'; popup_body.style.margin=pbpadding+'px'; } else { popup_body.style.top=0+'px'; popup_body.style.left=0+'px'; if (!customImage) popup_body.style.width=(width)+'px'; if (!customImage) popup_body.style.height=(height)+'px'; popup_body.style.padding=0+'px'; } popup_body.style.textAlign='center'; popup_body.innerHTML=pbHTML; popup_body.style.fontFamily='Arial'; popup_body.style.fontSize='10pt'; popup_body.style.zIndex='20001'; popup_frame.appendChild(popup_body); popup_frame.appendChild(popup_x); if (animate_popup) { start = 'ML'; switch(start) { default: case 'ML': var startX = -width; var startY = ((docHeight/2)-(height/2)); break; case 'TL': var startX = -width; var startY = -height; break; case 'BL': var startX = -width; var startY = docHeight; break; case 'TC': var startX = ((docWidth/2)-(width/2)); var startY = -height; break; case 'TR': var startX = docWidth; var startY = -height; break; case 'MR': var startX = docWidth; var startY = ((docHeight/2)-(height/2)); break; case 'BR': var startX = docWidth; var startY = docHeight; break; case 'BC': var startX = ((docWidth/2)-(width/2)); var startY = docHeight; break; } var scrollOffsets=QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.getScrollOffsets(); startX +=scrollOffsets[0]; startY +=scrollOffsets[1]; var targetX = ((docWidth/2)-(width/2))+scrollOffsets[0]; var targetY = ((docHeight/2)-(height/2))+scrollOffsets[1]; var duration = 3000; QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.animate(popup_frame, duration, {x:startX,y:startY}, {x:targetX,y:targetY}); } else { popup_frame.style.zoom=1; popup_frame.style.left = ((docWidth/2)-(width/2))+'px'; popup_frame.style.top = ((docHeight/2)-(height/2))+'px'; document.body.appendChild(popup_frame); } }, getWindowSize:function(){ var myWidth = 0, myHeight = 0; if( typeof( window.innerWidth ) == 'number' ) { //Non-IE myWidth = window.innerWidth; myHeight = window.innerHeight; } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) { //IE 6+ in 'standards compliant mode' myWidth = document.documentElement.clientWidth; myHeight = document.documentElement.clientHeight; } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) { //IE 4 compatible myWidth = document.body.clientWidth; myHeight = document.body.clientHeight; } return ([myWidth,myHeight]); }, getScrollOffsets:function(){ var scrOfX = 0, scrOfY = 0; if( typeof( window.pageYOffset ) == 'number' ) { //Netscape compliant scrOfY = window.pageYOffset; scrOfX = window.pageXOffset; } else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) { //DOM compliant scrOfY = document.body.scrollTop; scrOfX = document.body.scrollLeft; } else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) { //IE6 standards compliant mode scrOfY = document.documentElement.scrollTop; scrOfX = document.documentElement.scrollLeft; } return [ scrOfX, scrOfY ]; }, fixPNG:function(myImage,width,height) { var arVersion = navigator.appVersion.split("MSIE"); var version = parseFloat(arVersion[1]); if ((version >= 5.5) && (version < 8) && (document.body.filters)) { var customImage = false; var background = true; var xmultiple = 1.225; var ymultiple = 1.3; var mhoff = ((xmultiple-1)*width)/2; var mvoff = ((ymultiple-1)*height)/2; var node = document.createElement('span'); node.style.setAttribute('filter', "progid:DXImageTransform.Microsoft.AlphaImageLoader" + "(src=\'" + myImage.src + "\', sizingMethod='scale')"); node.style.width = '100%'; node.style.height = '100%'; node.style.display = 'inline-block'; node.style.zIndex='20000'; node.style.position='relative'; var frame = document.createElement('div'); var horizontal_offset = width*0.091837; var vertical_offset = height*0.115384; var iframeCover = document.createElement('IFRAME'); if (customImage) { iframeCover.style.height =height+'px'; iframeCover.style.width =width+'px'; iframeCover.style.top = mvoff+'px'; iframeCover.style.left = mhoff+'px'; } else { iframeCover.style.height =height-(2*vertical_offset)+'px'; iframeCover.style.width =width-(2*horizontal_offset)+'px'; iframeCover.style.top = vertical_offset+'px'; iframeCover.style.left = horizontal_offset+'px'; } iframeCover.style.zIndex = '19999'; iframeCover.style.position='absolute'; iframeCover.frameBorder='0'; iframeCover.src = 'http://lds.qualtrics.com/SE//static/q-generic/.9414483/img/blank.html'; frame.appendChild(iframeCover); frame.appendChild(node); return frame; } else { return myImage.cloneNode(false); } }, animate:function(element, duration, start, target) { element.style.left = start['x']+'px'; element.style.top = start['y']+'px'; document.body.appendChild(element); element.style.zoom=1; var currentTime = new Date(); var fps = 30; QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.slide(element, currentTime, duration, target,(1000/fps)); }, slide:function(element, startTime, duration, target, fps) { var currentTime = new Date(); var timeelapsed = currentTime-startTime; var timeleft = (duration-timeelapsed); var factorX = QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.inquad(timeelapsed/duration); var factorY = factorX; var left = element.style.left; var top = element.style.top; var curX = left.substring(0,left.indexOf('p')); var curY = top.substring(0,top.indexOf('p')); var diffX = curX-target['x']; var diffY = curY-target['y']; var tempX = diffX*factorX; var tempY = diffY*factorY; element.style.left = (curX-tempX)+'px'; element.style.top = (curY-tempY)+'px'; if (timeleft > 0) { setTimeout(function(){QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.slide(element, startTime, duration, target,fps);},fps); } else { element.style.left = target['x']; element.style.top = target['y']; element.style.zIndex=50000; } }, inquad:function(x) { return x*x}, surveyPopup:function(width,height,link) { options = "menubar=no,width="+width+",height="+height+",toolbar=no,location=no,status=no,scrollbars=yes" window.open(link,'Title',options); } } var displayPopup_SV_e9dKhJhAF4kXqKg = true; //may set displayPopup_SV_e9dKhJhAF4kXqKg to false depending on cookie settings function createQualtricsCookie(name,value,days,domain) { if (days) { var date = new Date(); date.setTime(date.getTime()+(days*24*60*60*1000)); var expires = "expires="+date.toGMTString(); } else var expires = ""; //Determine the domain (so all sub-domains can share same cookie) var cookieDomain = ''; if (domain && (domain != '')) { cookieDomain = "domain="+domain; } document.cookie = name+"="+value+"; "+expires+"; path=/; "+cookieDomain; } function readQualtricsCookie(name) { var nameEQ = name + "="; var ca = document.cookie.split(';'); for(var i=0;i < ca.length;i++) { var c = ca[i]; while (c.charAt(0)==' ') c = c.substring(1,c.length); if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length); } return null; } if (0 > 0) { //should be setting and checking cookie var cookieName = 'QualtricsPopup_SV_e9dKhJhAF4kXqKg'; //check to see if cookie exists if (readQualtricsCookie(cookieName)) { displayPopup_SV_e9dKhJhAF4kXqKg = false; } else { //set the cookie and show the popup createQualtricsCookie(cookieName,'1',0,''); displayPopup_SV_e9dKhJhAF4kXqKg = true; } } if (displayPopup_SV_e9dKhJhAF4kXqKg) { if ("" != "") { var cookieName = 'QualtricsPopup_global_'; if (readQualtricsCookie(cookieName)) { displayPopup_SV_e9dKhJhAF4kXqKg = false; } else { //set the cookie and show the popup createQualtricsCookie(cookieName,'1',356,''); displayPopup_SV_e9dKhJhAF4kXqKg = true; } } } if (displayPopup_SV_e9dKhJhAF4kXqKg) { window.setTimeout('QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.popup(400,250,1)', 180000); var closeDelay = 0; if (closeDelay != 0) window.setTimeout('QualtricsEmbeddedPopup_SV_e9dKhJhAF4kXqKg.close()', closeDelay); }