var AmConstant={COOKIE_NAME:"amcd",MAX_COOKIE_LENGTH:2040,TIME_OUT_COOKIE_NAME:"amtmot",IGNORE_TIME_OUT_COOKIE_NAME:"amignrtmot",EXELATE_COOKIE_NAME:"amexl",TIME_OUT_TOLLERANCE:15000,MAX_CATEGORIE_LENGTH:512000,CATEGORIE_SEPARATOR:",",COOKIE_US_NAME:"amcus",COOKIE_NAME_TEST_SERVER:"amts",SLOT_TOP:"amTop",PROTOCOL_HTTP:"http:",PROTOCOL_HTTPS:"https:",DOMAIN:"srv.amadesa.com",DOMAIN_PATTERN:"srv$NUMBER.amadesa.com",DOMAIN_PATTERN_NUMBER:"$NUMBER",ADMIN_DOMAIN:"manage.amadesa.com",STATIC_DOMAIN:"cache.amadesa.com",SECURE_STATIC_DOMAIN:"secure-cache.amadesa.com",DIRECT_APPS_REFRESH_NAME:"/direct/staticgen",DIRECT_APPS_REFRESH_COMMAND_NAME:"regenTestLazy",DIRECT_APPS_CHECK_REFRESH_COMMAND_NAME:"regenTestCheck",DIRECT_APPS_CHECK_HOLD_COMMAND_NAME:"regenDeploymentsCheck",APP_NAME:"/Interaction2/app",ETERN_DOMAIN:"etern.amadesa.com",SITE_PROP:"/static/sites/{siteId}/props",APP_INPLACE_NAME:"/Interaction2/appInplace",INT_PRODUCTS:"/Interaction2/products",INT_COUNTER:"/Interaction2/counter",INT_STUB:"/Interaction2/hitStub",IMAGE_CONTENT_TYPE:"image/gif",AM_DISABLE_AMADESA_COOKIE:"amDisableAmadesa",INPLACE_SUBSCRIPTION_REST_SUBSCRIBE:"/Interaction2/rest/inplace/subscription/subscribe",INPLACE_SUBSCRIPTION_REST_UNSUBSCRIBE:"/Interaction2/rest/inplace/subscription/unsubscribe",INPLACE_SITE_SUBSCRIPTION_REST:"/sites/",PRODUCT_COLLECT:"collect",SLOT_PPID:"0",CONTENT_HIDE:1,CONTENT_BLOCK:2,TEST_SERVER:"amtestserver",LIVE_SERVER:"amliveserver",PRODUCT_BASE_TEMPLATE:".base_template",PRODUCT_TEMPLATE:".product_template",AM_DEBUG:"amdebug",AM_CONTROL_EMPTY_CONTENT:"AM_CONTROL_EMPTY_CONTENT",AM_TEST_APP_REFRESH_REQUIRED:"REFRESH_REQUIRED",AM_TEST_APP_HOLD_REQUIRED:"HOLD_REQUIRED",AM_TEST_APP_HOLD_TIME_OUT_INTERVAL:1000,AM_TEST_APP_HOLD_COUNT_TOLLERANCE:30,AM_TEST_APP_REFRESH_DIVS_DISPLAY_TIME:1000,AM_UID_ARRAY_SERVER_ID:"SERVER_ID",AM_UID_ARRAY_USER_ID:"USER_ID",INPLACE_TAGGING_MODE_PARAM:"inplacetaggingmode",INPLACE_TAGGING_MODE_COOKIE_NAME:"amtagmod",INPLACE_FORCE_TAGGING_MODE:"amTaggingMode",Alias:{STATIC_URL:"%%SERVER_URL%%",COUNTER_URL:"%%SERVER_COUNTER_URL%%",USER_ID:"[USER_ID]",VISIT_ID:"[VISIT_ID]",HITS_COUNTER:"[HITS_COUNTER]",PROFILE_ID:"[PROFILE_ID]",EG_ID:"[EG_ID]"},ProtocolType:{HTTP:"0",HTTPS:"1"},TestType:{BEST_NEXT_ACTION:1,AB_TESTING:2,MULTI_VARIANT:3,BEHAVIORAL_TARGETING:4,RECOMMENDATION:5}};var AmJSON=new Object();(function($){$.stringify=function(o){return this.toJSON(o)},$.toJSON=function(o){var type=typeof (o);if(o===null){return"null"}if(type=="undefined"){return undefined}if(type=="number"||type=="boolean"){return o+""}if(type=="string"){return $.quoteString(o)}if(type=="object"){if(o.constructor===Date){var month=o.getUTCMonth()+1;if(month<10){month="0"+month}var day=o.getUTCDate();if(day<10){day="0"+day}var year=o.getUTCFullYear();var hours=o.getUTCHours();if(hours<10){hours="0"+hours}var minutes=o.getUTCMinutes();if(minutes<10){minutes="0"+minutes}var seconds=o.getUTCSeconds();if(seconds<10){seconds="0"+seconds}var milli=o.getUTCMilliseconds();if(milli<100){milli="0"+milli}if(milli<10){milli="0"+milli}return'"'+year+"-"+month+"-"+day+"T"+hours+":"+minutes+":"+seconds+"."+milli+'Z"'}if(o.constructor===Array){var ret=[];for(var i=0;i<o.length;i++){ret.push($.toJSON(o[i])||"null")}return"["+ret.join(",")+"]"}var pairs=[];for(var k in o){var name;var type=typeof k;if(type=="number"){name='"'+k+'"'}else{if(type=="string"){name=$.quoteString(k)}else{continue}}if(typeof o[k]=="function"){continue}var val=$.toJSON(o[k]);pairs.push(name+":"+val)}return"{"+pairs.join(", ")+"}"}};$.evalJSON=function(src){return eval("("+src+")")};$.secureEvalJSON=function(src){var filtered=src;filtered=filtered.replace(/\\["\\\/bfnrtu]/g,"@");filtered=filtered.replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]");filtered=filtered.replace(/(?:^|:|,)(?:\s*\[)+/g,"");if(/^[\],:{}\s]*$/.test(filtered)){return eval("("+src+")")}else{throw new SyntaxError("Error parsing JSON, source is not valid.")}};$.quoteString=function(string){if(string.match(_escapeable)){return'"'+string.replace(_escapeable,function(a){var c=_meta[a];if(typeof c==="string"){return c}c=a.charCodeAt();return"\\u00"+Math.floor(c/16).toString(16)+(c%16).toString(16)})+'"'}return'"'+string+'"'};var _escapeable=/["\\\x00-\x1f\x7f-\x9f]/g;var _meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"}})(AmJSON);function amGetQueryVariable(A){var C=window.location.search.substring(1);var D=C.split("&");for(var B=0;B<D.length;B++){var E=D[B].split("=");if(E[0].toLowerCase()==A.toLowerCase()){return E[1]}}return -1}var AmUtil={createAndAppendScript:function(A,B){document.body.appendChild(AmUtil.createScript(A,B))},createScript:function(B,C){var A=document.createElement("script");A.type=C?C:"text/javascript";A.src=B;return A},getProtocol:function(){var A=AmConstant.PROTOCOL_HTTP;if(document.location.protocol==AmConstant.PROTOCOL_HTTPS){A=AmConstant.PROTOCOL_HTTPS}return A},getProtocolType:function(){var A=AmConstant.ProtocolType.HTTP;if(document.location.protocol==AmConstant.PROTOCOL_HTTPS){A=AmConstant.ProtocolType.HTTPS}return A},getDomain:function(A){if(window.amDomainForced){return window.amDomainForced}else{if(A){return AmConstant.DOMAIN_PATTERN.replace(AmConstant.DOMAIN_PATTERN_NUMBER,A)}}return AmConstant.DOMAIN},getAppName:function(){return window.amAppNameForced?window.amAppNameForced:AmConstant.APP_NAME},getAppSuspense:function(){return window.amAppNameForced?window.amAppNameForced:AmConstant.APP_SUSPENSE},getSiteProps:function(){return window.amAppNameForced?window.amAppNameForced:AmConstant.SITE_PROP},getCounterURL:function(){return window.amDomainForced?this.assembleCounterURL():AmResponse.serverCounterURL},assembleCounterURL:function(){return AmUtil.getProtocol()+"//"+window.amDomainForced+AmConstant.INT_COUNTER+"?"},getCDomain:function(){var A="";if(window.amCDomainForced){A=";domain="+window.amCDomainForced}return A},getCookieExp:function(){var A=AmConstant.COOKIE_EXP;if(window.amCookieExpForced){A=window.amCookieExpForced}return A},getRandom:function(){return Math.ceil(Math.random()*10000000000000)},getScriptTag:function(B,A){var C=A?"id='"+A+"'":"";return'<script language="javascript" src="'+B+'" '+C+"><\/script>"},appendCss:function(B){B=this.convertAliases(B);var A=document.createElement("link");A.rel="stylesheet";A.href=B;var C=document.getElementsByTagName("head")[0];if(C){C.appendChild(A)}return A},appendStyle:function(D){var A=document.createElement("style");A.setAttribute("type","text/css");if(A.styleSheet){A.styleSheet.cssText=D}else{var B=document.createTextNode(D);A.appendChild(B)}var C=document.getElementsByTagName("head")[0];if(C){C.appendChild(A)}return A},isNumber:function(A){var B=A.toString().replace(/\,/g,"");return isFinite(B)},relplaceQuots:function(A){if(A){A=A.replace(/\'/g,"&#039;")}return A},replaceAll:function(A,E,C){var D=0;var B="";while(A.indexOf(E,D)!=-1){B+=A.substring(D,A.indexOf(E,D));B+=C;D=(A.indexOf(E,D)+E.length)}B+=A.substring(D,A.length);return B},getFirstResultOfRegExp:function(C,D){var A=AmUtil.runRegExp(C,D);var B;if(A&&A.length>1){B=A[1]}return B},runRegExp:function(B,C){var A=new RegExp(C,"g");return A.exec(B)},convertAliases:function(G,B){G=this.replaceAll(G,AmConstant.Alias.STATIC_URL,AmResponse.serverStaticURL);G=this.replaceAll(G,AmConstant.Alias.COUNTER_URL,this.getCounterURL());G=this.replaceAll(G,AmConstant.Alias.USER_ID,AmManager.getUserIDServerIDValue());G=this.replaceAll(G,AmConstant.Alias.VISIT_ID,AmCookie.visitID);G=this.replaceAll(G,AmConstant.Alias.HITS_COUNTER,AmCookie.hitsCounter);G=this.replaceAll(G,AmConstant.Alias.PROFILE_ID,AmCookie.profileID);if(B){G=this.replaceAll(G,AmConstant.Alias.EG_ID,B)}var F=/href.*?Interaction2\/counter.*?&red=[^\"]+/gi;var D=F.exec(G);while(D){var H=D.toString();var A=H.split("&red=");var J=A[0];for(var C=1;C<A.length;C=C+1){var E=A[C];if(E.match(/.*:.*/)){E=window.encodeURIComponent(E)}J+="&red="+E}var I=G.indexOf(H);G=G.substring(0,I)+J+G.substring(I+H.length);D=F.exec(G)}return G},counterIntervalImageRequest:0,sendImageRequest:function(C,A){var B=function(){var D=new Image();if(A){D.onload=A;D.onerror=A}C+="&rd="+AmUtil.getRandom();D.src=C;if(AmJSCookie.get(AmConstant.TIME_OUT_COOKIE_NAME)){D.src=location.href}};setTimeout(B,this.counterIntervalImageRequest);this.counterIntervalImageRequest+=100},attachEvent:function(C,A,B){if(C.addEventListener){C.addEventListener(A,B,false)}else{if(C.attachEvent){C.attachEvent("on"+A,B)}}},getQueryStringParam:function(A){return this.getQueryStringParamByURL(window.location.href,A)},getExactQueryStringParam:function(A){return this.getQueryStringParam("[?|&]"+A)},getQueryStringParamByURL:function(B,A){var E="";var D=A+"=([^&]+)";var F=new RegExp(D,"i");var C=F.exec(B);if(C&&C[1]){E=C[1]}return E},getQueryStringHash:function(G){var F=new AmHash();var E=/[^=|&]+/g;var C=G.match(E);for(var B=0;B<C.length;B=B+2){var A=C[B];var D=C[B+1];F.set(A,D)}return F},endsWith:function(B,A){return(B.match(A+"$")==A)},getStyleProperty:function(C,A){if(A=="width"){return C.offsetWidth}if(A=="height"){return C.offsetHeight}var B;if(typeof C.currentStyle!="undefined"){B=C.currentStyle;return B[A]}else{B=window.getComputedStyle(C,null);return B[A]}}};var AmJSCookie={set:function(C,D,E,A){var B=E?"":"Thu, 8 Oct 2201 15:59:28 UTC ";this.setWithExpiration(C,D,B,A)},deleteCookie:function(B,C,A){this.setWithExpiration(B,C,"Thu, 01-Jan-1970 00:00:01 GMT ",A)},setWithExpiration:function(C,E,F,A){var D=(A==undefined||A===true)?AmUtil.getCDomain():"";var B=F?";expires="+F:"";E=(E==undefined)?"":E;document.cookie=C+"="+escape(E)+B+D+"; path=/"},get:function(A){var B;var C="";if(document.cookie.length>0){B=document.cookie.lastIndexOf(A);if(B!=-1){B+=A.length;end=document.cookie.indexOf(";",B);if(end==-1){end=document.cookie.length}C=unescape(document.cookie.substring(B+1,end))}}return C},getCookieEnabled:function(){var A="0";if(typeof (navigator.cookieEnabled)!="undefined"){A=navigator.cookieEnabled?"0":"2"}if(A!="2"){AmJSCookie.set(AmConstant.COOKIE_US_NAME,"testUS",true,false);if(AmJSCookie.get(AmConstant.COOKIE_US_NAME).length<2){A="2"}AmJSCookie.set(AmConstant.COOKIE_US_NAME,"",true,false)}return A}};function AmHash(){this.items={};this.length=0;this.hasKey=function(A){return(A in this.items)};this.get=function(A){return(this.hasKey(A))?this.items[A]:null};this.set=function(A,B){if(!this.hasKey(A)){this.length++}this.items[A]=B};this.remove=function(A){if(this.hasKey(A)){delete this.items[A];this.length--}};this.empty=function(){this.items={};this.length=0}}var AmBase64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(C){var A="";var J,H,F,I,G,E,D;var B=0;C=AmBase64._utf8_encode(C);while(B<C.length){J=C.charCodeAt(B++);H=C.charCodeAt(B++);F=C.charCodeAt(B++);I=J>>2;G=((J&3)<<4)|(H>>4);E=((H&15)<<2)|(F>>6);D=F&63;if(isNaN(H)){E=D=64}else{if(isNaN(F)){D=64}}A=A+this._keyStr.charAt(I)+this._keyStr.charAt(G)+this._keyStr.charAt(E)+this._keyStr.charAt(D)}return A},decode:function(C){var A="";var J,H,F;var I,G,E,D;var B=0;C=C.replace(/[^A-Za-z0-9\+\/\=]/g,"");while(B<C.length){I=this._keyStr.indexOf(C.charAt(B++));G=this._keyStr.indexOf(C.charAt(B++));E=this._keyStr.indexOf(C.charAt(B++));D=this._keyStr.indexOf(C.charAt(B++));J=(I<<2)|(G>>4);H=((G&15)<<4)|(E>>2);F=((E&3)<<6)|D;A=A+String.fromCharCode(J);if(E!=64){A=A+String.fromCharCode(H)}if(D!=64){A=A+String.fromCharCode(F)}}A=AmBase64._utf8_decode(A);return A},_utf8_encode:function(B){B=B.replace(/\r\n/g,"\n");var A="";for(var D=0;D<B.length;D++){var C=B.charCodeAt(D);if(C<128){A+=String.fromCharCode(C)}else{if((C>127)&&(C<2048)){A+=String.fromCharCode((C>>6)|192);A+=String.fromCharCode((C&63)|128)}else{A+=String.fromCharCode((C>>12)|224);A+=String.fromCharCode(((C>>6)&63)|128);A+=String.fromCharCode((C&63)|128)}}}return A},_utf8_decode:function(A){var B="";var C=0;var D=c1=c2=0;while(C<A.length){D=A.charCodeAt(C);if(D<128){B+=String.fromCharCode(D);C++}else{if((D>191)&&(D<224)){c2=A.charCodeAt(C+1);B+=String.fromCharCode(((D&31)<<6)|(c2&63));C+=2}else{c2=A.charCodeAt(C+1);c3=A.charCodeAt(C+2);B+=String.fromCharCode(((D&15)<<12)|((c2&63)<<6)|(c3&63));C+=3}}}return B}};(function(){var C="false"==="true";var A=new Array();var B=function(){};B.prototype.getSessionLog=function(){return A};B.prototype.log=function(F,D){try{var H="";try{for(var E=0;E<D.length;E++){H+=JSON.stringify(D[E])+((E+1)==D.length?"":", ")}}catch(G){}if(!H){H=""}A.push(F.concat(H));if(!C){return }console.log(F)}catch(G){}};window.AmLoggerAPI=new B()})();(function(){var C="true"==="true";var A=window.AmLoggerAPI;var D=(("https:"==document.location.protocol)?"https://":"http://")+"notify.amadesa.com/sites/{siteId}/rest/clientside/errors?detailsObj=";var B=function(){};B.prototype.getClientInfo=function(){var E=navigator.userAgent.toLowerCase();var J={};var K=/(webkit)[ \/]([\w.]+)/;var F=/(opera)(?:.*version)?[ \/]([\w.]+)/;var L=/(msie) ([\w.]+)/;var I=/(mozilla)(?:.*? rv:([\w.]+))?/;var H=K.exec(E)||F.exec(E)||L.exec(E)||E.indexOf("compatible")<0&&I.exec(E)||[];var G={browser:H[1]||"",version:H[2]||"0"};var M={browser:{},browserVer:""};if(G.browser){M.browser[G.browser]=true;M.browser.version=G.version}if(M.browser.msie){J.browser="IE"}else{if(M.browser.mozilla){J.browser="GECKO"}else{if(M.browser.opera){J.browser="OPERA"}else{if(M.browser.webkit){J.browser="WEBKIT"}}}}J.browserVer=M.browser.version;J.secure="https:"==document.location.protocol;J.os=navigator.platform;J.location=window.location?window.location.href:"";if((/windows|win32/i).test(J.os)){J.os="windows"}return J};B.prototype.log=function(K,R){try{if(!C){try{console.log("An error has happened: "+K+" ex: "+R)}catch(T){}}var H;var P;var G=null;var M;var F;var E;var I="";var U={};var L=new Array();var W=new Array();var S=new Array();M=this.getClientInfo();F=new Date().getTime();E=K+"\n"+R.message;try{H=AmManager.getCookieFromEntrenceURL();P=AmManager.getUserIDAndServerIDAsArray(H[AmConstant.COOKIE_NAME])||new Array();P=P.toString()}catch(T){}try{I=document.cookie}catch(T){}try{U=amPageSummary.amPageSummary.globalControl}catch(T){}try{L=new Array();for(var Q in AmContentManager.contents.items){var N=AmContentManager.contents.items[Q];L.push({slot:Q,testId:N.testID,webletId:N.webletID})}}catch(T){}try{W=new Array();for(var O in amPageSummary.amPageSummary.selectedVirtualSlots){var V=amPageSummary.amPageSummary.selectedVirtualSlots[O];W.push(V.name)}}catch(T){}try{S=new Array();for(var N in AmContentManager.executedElementsSet.items){S.push(N)}}catch(T){}var J={origin:"VISUAL_SNIFFER",location:M.location,errorTime:F,accountId:-1,siteId:amPid,pageId:amPPid,userId:P,errorMessage:E,browser:M.browser,browserVer:M.browserVer,secure:M.secure,os:M.os,traceLog:G,cookie:I,gc:U,slots:L,vslotsNames:W,executedSlotsNames:S};B.reportError(J)}catch(T){}};B.reportError=function(E){var F=window.encodeURIComponent(AmBase64.encode(JSON.stringify(E)));var G=document.createElement("img");G.src=D.replace("{siteId}",amPid).concat(F);document.body.appendChild(G)};window.AmErrorLoggerAPI=new B()})();var amMobileUserAgentDetection={amIsTablet:false,amIsSmartPhone:false,amMobileUagent:null,isIphone:false,isAndroidPhone:false,isTierTablet:false,isTierIphone:false,isTierRichCss:false,isTierGenericMobile:false,engineWebKit:"webkit",deviceIphone:"iphone",deviceIpod:"ipod",deviceIpad:"ipad",deviceMacPpc:"macintosh",deviceAndroid:"android",deviceGoogleTV:"googletv",deviceXoom:"xoom",deviceHtcFlyer:"htc_flyer",deviceNuvifone:"nuvifone",deviceSymbian:"symbian",deviceS60:"series60",deviceS70:"series70",deviceS80:"series80",deviceS90:"series90",deviceWinPhone7:"windows phone os 7",deviceWinMob:"windows ce",deviceWindows:"windows",deviceIeMob:"iemobile",devicePpc:"ppc",enginePie:"wm5 pie",deviceBB:"blackberry",vndRIM:"vnd.rim",deviceBBStorm:"blackberry95",deviceBBBold:"blackberry97",deviceBBTour:"blackberry96",deviceBBCurve:"blackberry89",deviceBBTorch:"blackberry 98",deviceBBPlaybook:"playbook",devicePalm:"palm",deviceWebOS:"webos",deviceWebOShp:"hpwos",engineBlazer:"blazer",engineXiino:"xiino",deviceKindle:"kindle",vndwap:"vnd.wap",wml:"wml",deviceTablet:"tablet",deviceBrew:"brew",deviceDanger:"danger",deviceHiptop:"hiptop",devicePlaystation:"playstation",deviceNintendoDs:"nitro",deviceNintendo:"nintendo",deviceWii:"wii",deviceXbox:"xbox",deviceArchos:"archos",engineOpera:"opera",engineNetfront:"netfront",engineUpBrowser:"up.browser",engineOpenWeb:"openweb",deviceMidp:"midp",uplink:"up.link",engineTelecaQ:"teleca q",devicePda:"pda",mini:"mini",mobile:"mobile",mobi:"mobi",maemo:"maemo",linux:"linux",qtembedded:"qt embedded",mylocom2:"com2",manuSonyEricsson:"sonyericsson",manuericsson:"ericsson",manuSamsung1:"sec-sgh",manuSony:"sony",manuHtc:"htc",svcDocomo:"docomo",svcKddi:"kddi",svcVodafone:"vodafone",disUpdate:"update",uagent:((navigator&&navigator.userAgent)?uagent=navigator.userAgent.toLowerCase():""),DetectIphone:function(){if(this.uagent.search(this.deviceIphone)>-1){if(this.DetectIpad()||this.DetectIpod()){return false}else{return true}}else{return false}},DetectIpod:function(){if(this.uagent.search(this.deviceIpod)>-1){return true}else{return false}},DetectIpad:function(){if(this.uagent.search(this.deviceIpad)>-1&&this.DetectWebkit()){return true}else{return false}},DetectIphoneOrIpod:function(){if(this.uagent.search(this.deviceIphone)>-1||this.uagent.search(this.deviceIpod)>-1){return true}else{return false}},DetectIos:function(){if(this.DetectIphoneOrIpod()||this.DetectIpad()){return true}else{return false}},DetectAndroid:function(){if((this.uagent.search(this.deviceAndroid)>-1)||this.DetectGoogleTV()){return true}if(this.uagent.search(this.deviceHtcFlyer)>-1){return true}else{return false}},DetectAndroidPhone:function(){if(this.DetectAndroid()&&(this.uagent.search(this.mobile)>-1)){return true}if(this.DetectOperaAndroidPhone()){return true}if(this.uagent.search(this.deviceHtcFlyer)>-1){return true}else{return false}},DetectAndroidTablet:function(){if(!this.DetectAndroid()){return false}if(this.DetectOperaMobile()){return false}if(this.uagent.search(this.deviceHtcFlyer)>-1){return false}if(this.uagent.search(this.mobile)>-1){return false}else{return true}},DetectAndroidWebKit:function(){if(this.DetectAndroid()&&this.DetectWebkit()){return true}else{return false}},DetectGoogleTV:function(){if(this.uagent.search(this.deviceGoogleTV)>-1){return true}else{return false}},DetectWebkit:function(){if(this.uagent.search(this.engineWebKit)>-1){return true}else{return false}},DetectS60OssBrowser:function(){if(this.DetectWebkit()){if((this.uagent.search(this.deviceS60)>-1||this.uagent.search(this.deviceSymbian)>-1)){return true}else{return false}}else{return false}},DetectSymbianOS:function(){if(this.uagent.search(this.deviceSymbian)>-1||this.uagent.search(this.deviceS60)>-1||this.uagent.search(this.deviceS70)>-1||this.uagent.search(this.deviceS80)>-1||this.uagent.search(this.deviceS90)>-1){return true}else{return false}},DetectWindowsPhone7:function(){if(this.uagent.search(this.deviceWinPhone7)>-1){return true}else{return false}},DetectWindowsMobile:function(){if(this.DetectWindowsPhone7()){return false}if(this.uagent.search(this.deviceWinMob)>-1||this.uagent.search(this.deviceIeMob)>-1||this.uagent.search(this.enginePie)>-1){return true}if((this.uagent.search(this.devicePpc)>-1)&&!(this.uagent.search(this.deviceMacPpc)>-1)){return true}if(this.uagent.search(this.manuHtc)>-1&&this.uagent.search(this.deviceWindows)>-1){return true}else{return false}},DetectBlackBerry:function(){if(this.uagent.search(this.deviceBB)>-1){return true}if(this.uagent.search(this.vndRIM)>-1){return true}else{return false}},DetectBlackBerryTablet:function(){if(this.uagent.search(this.deviceBBPlaybook)>-1){return true}else{return false}},DetectBlackBerryWebKit:function(){if(this.DetectBlackBerry()&&this.uagent.search(this.engineWebKit)>-1){return true}else{return false}},DetectBlackBerryTouch:function(){if(this.DetectBlackBerry()&&((this.uagent.search(this.deviceBBStorm)>-1)||(this.uagent.search(this.deviceBBTorch)>-1))){return true}else{return false}},DetectBlackBerryHigh:function(){if(this.DetectBlackBerryWebKit()){return false}if(this.DetectBlackBerry()){if(this.DetectBlackBerryTouch()||this.uagent.search(this.deviceBBBold)>-1||this.uagent.search(this.deviceBBTour)>-1||this.uagent.search(this.deviceBBCurve)>-1){return true}else{return false}}else{return false}},DetectBlackBerryLow:function(){if(this.DetectBlackBerry()){if(this.DetectBlackBerryHigh()||this.DetectBlackBerryWebKit()){return false}else{return true}}else{return false}},DetectPalmOS:function(){if(this.uagent.search(this.devicePalm)>-1||this.uagent.search(this.engineBlazer)>-1||this.uagent.search(this.engineXiino)>-1){if(this.DetectPalmWebOS()){return false}else{return true}}else{return false}},DetectPalmWebOS:function(){if(this.uagent.search(this.deviceWebOS)>-1){return true}else{return false}},DetectWebOSTablet:function(){if(this.uagent.search(this.deviceWebOShp)>-1&&this.uagent.search(this.deviceTablet)>-1){return true}else{return false}},DetectGarminNuvifone:function(){if(this.uagent.search(this.deviceNuvifone)>-1){return true}else{return false}},DetectSmartphone:function(){if(this.DetectIphoneOrIpod()||this.DetectAndroidPhone()||this.DetectS60OssBrowser()||this.DetectSymbianOS()||this.DetectWindowsMobile()||this.DetectWindowsPhone7()||this.DetectBlackBerry()||this.DetectPalmWebOS()||this.DetectPalmOS()||this.DetectGarminNuvifone()){return true}return false},DetectArchos:function(){if(this.uagent.search(this.deviceArchos)>-1){return true}else{return false}},DetectBrewDevice:function(){if(this.uagent.search(this.deviceBrew)>-1){return true}else{return false}},DetectDangerHiptop:function(){if(this.uagent.search(this.deviceDanger)>-1||this.uagent.search(this.deviceHiptop)>-1){return true}else{return false}},DetectMaemoTablet:function(){if(this.uagent.search(this.maemo)>-1){return true}if((this.uagent.search(this.linux)>-1)&&(this.uagent.search(this.deviceTablet)>-1)&&!this.DetectWebOSTablet()&&!this.DetectAndroid()){return true}else{return false}},DetectSonyMylo:function(){if(this.uagent.search(this.manuSony)>-1){if(this.uagent.search(this.qtembedded)>-1||this.uagent.search(this.mylocom2)>-1){return true}else{return false}}else{return false}},DetectOperaMobile:function(){if(this.uagent.search(this.engineOpera)>-1){if(this.uagent.search(this.mini)>-1||this.uagent.search(this.mobi)>-1){return true}else{return false}}else{return false}},DetectOperaAndroidPhone:function(){if((this.uagent.search(this.engineOpera)>-1)&&(this.uagent.search(this.deviceAndroid)>-1)&&(this.uagent.search(this.mobi)>-1)){return true}else{return false}},DetectOperaAndroidTablet:function(){if((this.uagent.search(this.engineOpera)>-1)&&(this.uagent.search(this.deviceAndroid)>-1)&&(this.uagent.search(this.deviceTablet)>-1)){return true}else{return false}},DetectSonyPlaystation:function(){if(this.uagent.search(this.devicePlaystation)>-1){return true}else{return false}},DetectNintendo:function(){if(this.uagent.search(this.deviceNintendo)>-1||this.uagent.search(this.deviceWii)>-1||this.uagent.search(this.deviceNintendoDs)>-1){return true}else{return false}},DetectXbox:function(){if(this.uagent.search(this.deviceXbox)>-1){return true}else{return false}},DetectGameConsole:function(){if(this.DetectSonyPlaystation()){return true}if(this.DetectNintendo()){return true}if(this.DetectXbox()){return true}else{return false}},DetectKindle:function(){if(this.uagent.search(this.deviceKindle)>-1){return true}else{return false}},DetectMobileQuick:function(){if(this.DetectTierTablet()){return false}if(this.DetectSmartphone()){return true}if(this.uagent.search(this.deviceMidp)>-1||this.DetectBrewDevice()){return true}if(this.DetectOperaMobile()){return true}if(this.uagent.search(this.engineNetfront)>-1){return true}if(this.uagent.search(this.engineUpBrowser)>-1){return true}if(this.uagent.search(this.engineOpenWeb)>-1){return true}if(this.DetectDangerHiptop()){return true}if(this.DetectMaemoTablet()){return true}if(this.DetectArchos()){return true}if((this.uagent.search(this.devicePda)>-1)&&!(this.uagent.search(this.disUpdate)>-1)){return true}if(this.uagent.search(this.mobile)>-1){return true}if(this.DetectKindle()){return true}return false},DetectMobileLong:function(){if(this.DetectMobileQuick()){return true}if(this.DetectGameConsole()){return true}if(this.DetectSonyMylo()){return true}if(this.uagent.search(this.manuSamsung1)>-1||this.uagent.search(this.manuSonyEricsson)>-1||this.uagent.search(this.manuericsson)>-1){return true}if(this.uagent.search(this.svcDocomo)>-1){return true}if(this.uagent.search(this.svcKddi)>-1){return true}if(this.uagent.search(this.svcVodafone)>-1){return true}return false},DetectTierTablet:function(){if(this.DetectIpad()||this.DetectAndroidTablet()||this.DetectBlackBerryTablet()||this.DetectWebOSTablet()){return true}else{return false}},DetectTierIphone:function(){if(this.DetectIphoneOrIpod()){return true}if(this.DetectAndroidPhone()){return true}if(this.DetectBlackBerryWebKit()&&this.DetectBlackBerryTouch()){return true}if(this.DetectPalmWebOS()){return true}if(this.DetectGarminNuvifone()){return true}else{return false}},DetectTierRichCss:function(){if(this.DetectMobileQuick()){if(this.DetectTierIphone()){return false}if(this.DetectWebkit()){return true}if(this.DetectS60OssBrowser()){return true}if(this.DetectBlackBerryHigh()){return true}if(this.DetectWindowsPhone7()){return true}if(this.DetectWindowsMobile()){return true}if(this.uagent.search(this.engineTelecaQ)>-1){return true}else{return false}}else{return false}},DetectTierOtherPhones:function(){if(this.DetectMobileLong()){if(this.DetectTierIphone()||this.DetectTierRichCss()){return false}else{return true}}else{return false}},InitDeviceScan:function(){this.isTierIphone=this.DetectTierIphone();this.isTierTablet=this.DetectTierTablet();this.isTierRichCss=this.DetectTierRichCss();this.amIsTablet=this.isTierTablet;this.amIsSmartPhone=this.isTierIphone||this.isTierRichCss;this.amMobileUagent=this.uagent}};amMobileUserAgentDetection.InitDeviceScan();var amUseGeoLocation=amMobileUserAgentDetection.amIsTablet||amMobileUserAgentDetection.amIsSmartPhone;if(amGetQueryVariable("amForceSmartphone")!=-1||amGetQueryVariable("amForceTablet")!=-1){amUseGeoLocation=amGetQueryVariable("amForceSmartphone").toString().toLowerCase()=="true"||amGetQueryVariable("amForceTablet").toString().toLowerCase()=="true";amMobileUserAgentDetection.amIsTablet=amGetQueryVariable("amForceTablet").toString().toLowerCase()=="true";amMobileUserAgentDetection.amIsSmartPhone=amGetQueryVariable("amForceSmartphone").toString().toLowerCase()=="true"}var amForceGeoData=null;if(amGetQueryVariable("amForceGeo")!=-1){var forceData=amGetQueryVariable("amForceGeo").split(",");amForceGeoData={};amForceGeoData.lat=forceData[0]||null;amForceGeoData.lon=forceData[1]||null;amForceGeoData.accuracy=forceData[2]||null}var amGeoLocationData=null;var amAdvancedSiteProperties=null;AmGeoLocationDataHandler={logger:window.AmLoggerAPI,status:null,data:null,set:function(B,C){if(window.amGeoLocationData){return }this.status=C;if(B){this.data=B;if(B.error&&B.error.code){this.logger.log("Err: "+B.error.code+"> "+(B.error.code==1?"GEO>PERMISSION_DENIED":B.error.code==2?"GEO>POSITION_UNAVAILABLE":B.error.code==3?"GEO>TIMEOUT":"AM>"+(B.error.desc||"unknown")))}var A={status:C,response:B};window.amGeoLocationData=A}},getStatus:function(){return this.status},getData:function(){return this.data}};var AmGeoLocation={logger:window.AmLoggerAPI,callbackFunction:function(A){window.AmGeoLocationDataHandler.set(A,"success")},callbackErrorFunction:function(A){window.AmGeoLocationDataHandler.set({error:A},"failed")},init:function(){var A;AmGeoManager.setGeoLocationStartTime();if(!window.amAdvancedSiteProperties){this.logger.log("GeoLocation - failed: no advanced properties");window.AmGeoLocationDataHandler.set({error:{code:"77"}},"failed");return }AmGeoManager.setGeoLocationWaitingTime(window.amAdvancedSiteProperties.timeout);if(amForceGeoData&&amForceGeoData.lat&&amForceGeoData.lon&&amForceGeoData.accuracy){this.setForceGeoLocation()}else{this.startGeoLocator()}},setForceGeoLocation:function(){var A={coords:{longitude:amForceGeoData.lon,latitude:amForceGeoData.lat,accuracy:amForceGeoData.accuracy},timestamp:0};AmGeoLocation.callbackFunction(A)},startGeoLocator:function(){try{if(typeof (navigator.geolocation)=="undefined"){gl=google.gears.factory.create("beta.geolocation")}else{gl=navigator.geolocation}}catch(B){this.logger.log("GeoLocation - failed: no navigator.geolocation");window.AmGeoLocationDataHandler.set({error:{code:"55"}},"failed")}if(gl){var A={};A.enableHighAccuracy=window.amAdvancedSiteProperties.enableHighAccuracy;A.timeout=window.amAdvancedSiteProperties.timeout;A.maximumAge=window.amAdvancedSiteProperties.maximumAge;if(window.navigator&&window.navigator.userAgent&&window.navigator.userAgent.toLowerCase().indexOf("ie 9")>-1){gl.watchPosition(AmGeoLocation.callbackFunction,AmGeoLocation.callbackErrorFunction,A)}else{gl.getCurrentPosition(AmGeoLocation.callbackFunction,AmGeoLocation.callbackErrorFunction,A)}}else{this.logger.log("GeoLocation - failed: client does not support geo location");window.AmGeoLocationDataHandler.set({error:{code:"55"}},"failed")}}};(function(){window.AmJS={inArray:function(C,A){for(var B=0;B<A.length;B++){if(A[B]==C){return B}}return -1},$id:function(A){return AmSizzle("#"+A)},$class:function(A){return document.querySelectorAll("."+A)},attr:function(B,A,C){if(C){return B.getAttribute(A)==C}return B.getAttribute(A)},index:function(B){var A=0;while(B.previousSibling){if(B.previousSibling.nodeName!="#text"&&B.previousSibling.nodeName!="#comment"){A++}B=B.previousSibling}return A},is:function(B,A){return B.nodeName.toLowerCase()==A},$childIndex:function(D){var A=D.parentNode.childNodes;var C=0;for(var B=0;B<A.length;B++){if(A[B]==D){return((A[B].tagName)=="TR"?" > tbody":"")+" > "+(A[B].tagName).toLowerCase()+":eq("+C+")";break}if((A[B]).tagName&&(A[B].tagName.toLowerCase()==D.tagName.toLowerCase())){C++}}}}})(window);(function(){var P=window.AmLoggerAPI;var K={};var I={};I.id=({label:"",risk:"0",callback:function(R){return G(R)}});I["class"]=({label:"",risk:"0",callback:function(R){return N(R)}});I.name=({label:"",risk:"0",callback:function(R){return Q(R,"name")}});I.title=({label:"",risk:"0",callback:function(R){return Q(R,"title")}});I.src=({label:"",risk:"0",callback:function(R){return Q(R,"src")}});I.href=({label:"",risk:"0",callback:function(R){return Q(R,"href")}});I.body=({label:"",risk:"0",callback:function(){return E()}});var H=["ID","CLASS","NAME","TITLE","SRC","HREF"];var B={css3:"CSS3",sizzle:"SIZZLE"};var A=["TBODY","THEAD","TFOOT"];var C=function(R){K=R};C.prototype.getSelector=function(R){return L(R)};C.prototype.getElementBySelector=function(S){var R=AmSizzle(S);if(!R||R.length!=1){P.log("Cannot find a unique element for expression: "+S);return null}P.log("Found a unique element for expression: "+S);return R[0]};var L=function(R){return D(R)};var D=function(W,a){var S={};var U;var R;var X,b;var Z;var c;if(W&&W.nodeType==1){var d=""+W.tagName.toUpperCase();Z=false;c=(K.inArray(d,A)>-1);if(!c){for(var T=0;T<H.length;T++){attrData=I[H[T].toLowerCase()];X=H[T].toLowerCase();if(K.attr(W,X)){b=(attrData.callback)(W);if(!b){Z=false;continue}b.am_xpath=b.am_xpath+(a?a:"");Z=true;S=b;return S}}}if(!Z){var V=(a?a:"");if(!c){var Y=K.$childIndex(W);V=Y+V}if(W.parentNode.tagName.toLowerCase()=="body"){attrData=I.body;b=(attrData.callback)();b.am_xpath="body"+V;S=b;return S}return D(W.parentNode,V)}}};function G(R){var S=K.$id(K.attr(R,"id"));if(S.length==1){returnValue={};returnValue.am_risk=I.id.risk;returnValue.am_xpath=R.tagName.toLowerCase()+"#"+K.attr(R,"id");returnValue.am_css=B.css3;return returnValue}return false}function N(T){var U={};var W=J(T);var V=W.idx;var R=W.len;var S=F(K.attr(T,"class"));U.am_risk=I["class"].risk;U.am_xpath=T.tagName.toLowerCase()+"."+S+((R>1)?":eq("+V+")":"");U.am_css=(R>1)?B.sizzle:B.css3;return U}function Q(U,Y){var W={};var V=M(U,Y);var X=V.idx;var S=V.len;W.am_risk=I[Y].risk;var T=K.attr(U,Y);var R=U.tagName.toLowerCase();if(S>1){W.am_xpath=R+"["+Y+"='"+T+"']:eq("+X+")";W.am_css=B.sizzle;return W}W.am_xpath=R+"["+Y+"='"+T+"']";W.am_css=B.css3;return W}function E(){var R={};R.am_risk=I.body.risk;R.am_css=B.sizzle;return R}function O(S){var T=1;for(var R=S.previousSibling;R;R=R.previousSibling){if(R.nodeType==1&&R.tagName==S.tagName){T++}}return T}var F=function(R){var S=new RegExp(" ","ig");return(R.replace(S,"."))};var J=function(T){var S=F(K.attr(T,"class"));var R=AmSizzle(T.nodeName+"."+S);if(R.length<=1){return{idx:0,len:R.length}}for(var U=0;U<R.length;U++){if(R[U]==T){return{idx:U,len:R.length}}}};var M=function(S,V){var R=S.tagName.toLowerCase();var U=R+"["+V+"='"+K.attr(S,V)+"']";var T=AmSizzle(U);if(T.length<=1){return{idx:0,len:T.length}}for(var W=0;W<T.length;W++){if(T[W]==S){return{idx:W,len:T.length}}}};window.AmSelectionAPI=new C(window.AmJS)})();
/*
 * Sizzle CSS Selector Engine
 *  Copyright 2011, The Dojo Foundation
 *  Released under the MIT, BSD, and GPL Licenses.
 *  More information: http://sizzlejs.com/
 */
(function(){var K=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,L=0,O=Object.prototype.toString,F=false,E=true,M=/\\/g,S=/\W/;[0,0].sort(function(){E=false;return 0});var C=function(Y,T,b,c){b=b||[];T=T||document;var e=T;if(T.nodeType!==1&&T.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return b}var V,g,n,U,f,l,h,a,X=true,W=C.isXML(T),Z=[],d=Y;do{K.exec("");V=K.exec(d);if(V){d=V[3];Z.push(V[1]);if(V[2]){U=V[3];break}}}while(V);if(Z.length>1&&G.exec(Y)){if(Z.length===2&&H.relative[Z[0]]){g=P(Z[0]+Z[1],T)}else{g=H.relative[Z[0]]?[T]:C(Z.shift(),T);while(Z.length){Y=Z.shift();if(H.relative[Y]){Y+=Z.shift()}g=P(Y,g)}}}else{if(!c&&Z.length>1&&T.nodeType===9&&!W&&H.match.ID.test(Z[0])&&!H.match.ID.test(Z[Z.length-1])){f=C.find(Z.shift(),T,W);T=f.expr?C.filter(f.expr,f.set)[0]:f.set[0]}if(T){f=c?{expr:Z.pop(),set:I(c)}:C.find(Z.pop(),Z.length===1&&(Z[0]==="~"||Z[0]==="+")&&T.parentNode?T.parentNode:T,W);g=f.expr?C.filter(f.expr,f.set):f.set;if(Z.length>0){n=I(g)}else{X=false}while(Z.length){l=Z.pop();h=l;if(!H.relative[l]){l=""}else{h=Z.pop()}if(h==null){h=T}H.relative[l](n,h,W)}}else{n=Z=[]}}if(!n){n=g}if(!n){C.error(l||Y)}if(O.call(n)==="[object Array]"){if(!X){b.push.apply(b,n)}else{if(T&&T.nodeType===1){for(a=0;n[a]!=null;a++){if(n[a]&&(n[a]===true||n[a].nodeType===1&&C.contains(T,n[a]))){b.push(g[a])}}}else{for(a=0;n[a]!=null;a++){if(n[a]&&n[a].nodeType===1){b.push(g[a])}}}}}else{I(n,b)}if(U){C(U,e,b,c);C.uniqueSort(b)}return b};C.uniqueSort=function(U){if(N){F=E;U.sort(N);if(F){for(var T=1;T<U.length;T++){if(U[T]===U[T-1]){U.splice(T--,1)}}}}return U};C.matches=function(T,U){return C(T,null,null,U)};C.matchesSelector=function(T,U){return C(U,null,null,[T]).length>0};C.find=function(a,T,b){var Z;if(!a){return[]}for(var W=0,V=H.order.length;W<V;W++){var X,Y=H.order[W];if((X=H.leftMatch[Y].exec(a))){var U=X[1];X.splice(1,1);if(U.substr(U.length-1)!=="\\"){X[1]=(X[1]||"").replace(M,"");Z=H.find[Y](X,T,b);if(Z!=null){a=a.replace(H.match[Y],"");break}}}}if(!Z){Z=typeof T.getElementsByTagName!=="undefined"?T.getElementsByTagName("*"):[]}return{set:Z,expr:a}};C.filter=function(e,d,h,X){var Z,T,V=e,m=[],b=d,a=d&&d[0]&&C.isXML(d[0]);while(e&&d.length){for(var c in H.filter){if((Z=H.leftMatch[c].exec(e))!=null&&Z[2]){var l,g,U=H.filter[c],W=Z[1];T=false;Z.splice(1,1);if(W.substr(W.length-1)==="\\"){continue}if(b===m){m=[]}if(H.preFilter[c]){Z=H.preFilter[c](Z,b,h,m,X,a);if(!Z){T=l=true}else{if(Z===true){continue}}}if(Z){for(var Y=0;(g=b[Y])!=null;Y++){if(g){l=U(g,Z,Y,b);var f=X^!!l;if(h&&l!=null){if(f){T=true}else{b[Y]=false}}else{if(f){m.push(g);T=true}}}}}if(l!==undefined){if(!h){b=m}e=e.replace(H.match[c],"");if(!T){return[]}break}}}if(e===V){if(T==null){C.error(e)}else{break}}V=e}return b};C.error=function(T){throw"Syntax error, unrecognized expression: "+T};var H=C.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(T){return T.getAttribute("href")},type:function(T){return T.getAttribute("type")}},relative:{"+":function(Z,U){var W=typeof U==="string",Y=W&&!S.test(U),a=W&&!Y;if(Y){U=U.toLowerCase()}for(var V=0,T=Z.length,X;V<T;V++){if((X=Z[V])){while((X=X.previousSibling)&&X.nodeType!==1){}Z[V]=a||X&&X.nodeName.toLowerCase()===U?X||false:X===U}}if(a){C.filter(U,Z,true)}},">":function(Z,U){var Y,X=typeof U==="string",V=0,T=Z.length;if(X&&!S.test(U)){U=U.toLowerCase();for(;V<T;V++){Y=Z[V];if(Y){var W=Y.parentNode;Z[V]=W.nodeName.toLowerCase()===U?W:false}}}else{for(;V<T;V++){Y=Z[V];if(Y){Z[V]=X?Y.parentNode:Y.parentNode===U}}if(X){C.filter(U,Z,true)}}},"":function(W,U,Y){var X,V=L++,T=Q;if(typeof U==="string"&&!S.test(U)){U=U.toLowerCase();X=U;T=A}T("parentNode",U,V,W,X,Y)},"~":function(W,U,Y){var X,V=L++,T=Q;if(typeof U==="string"&&!S.test(U)){U=U.toLowerCase();X=U;T=A}T("previousSibling",U,V,W,X,Y)}},find:{ID:function(U,V,W){if(typeof V.getElementById!=="undefined"&&!W){var T=V.getElementById(U[1]);return T&&T.parentNode?[T]:[]}},NAME:function(V,Y){if(typeof Y.getElementsByName!=="undefined"){var U=[],X=Y.getElementsByName(V[1]);for(var W=0,T=X.length;W<T;W++){if(X[W].getAttribute("name")===V[1]){U.push(X[W])}}return U.length===0?null:U}},TAG:function(T,U){if(typeof U.getElementsByTagName!=="undefined"){return U.getElementsByTagName(T[1])}}},preFilter:{CLASS:function(W,U,V,T,Z,a){W=" "+W[1].replace(M,"")+" ";if(a){return W}for(var X=0,Y;(Y=U[X])!=null;X++){if(Y){if(Z^(Y.className&&(" "+Y.className+" ").replace(/[\t\n\r]/g," ").indexOf(W)>=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(M,"")},TAG:function(U,T){return U[1].replace(M,"").toLowerCase()},CHILD:function(T){if(T[1]==="nth"){if(!T[2]){C.error(T[0])}T[2]=T[2].replace(/^\+|\s*/g,"");var U=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(T[2]==="even"&&"2n"||T[2]==="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}else{if(T[2]){C.error(T[0])}}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1]=X[1].replace(M,"");if(!Z&&H.attrMap[W]){X[1]=H.attrMap[W]}X[4]=(X[4]||X[5]||"").replace(M,"");if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if((K.exec(X[3])||"").length>1||/^\w/.test(X[3])){X[3]=C(X[3],null,null,U)}else{var W=C.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(H.match.POS.test(X[0])||H.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){if(T.parentNode){T.parentNode.selectedIndex}return T.selected===true},parent:function(T){return !!T.firstChild},empty:function(T){return !T.firstChild},has:function(V,U,T){return !!C(T[3],V).length},header:function(T){return(/h\d/i).test(T.nodeName)},text:function(V){var T=V.getAttribute("type"),U=V.type;return V.nodeName.toLowerCase()==="input"&&"text"===U&&(T===U||T===null)},radio:function(T){return T.nodeName.toLowerCase()==="input"&&"radio"===T.type},checkbox:function(T){return T.nodeName.toLowerCase()==="input"&&"checkbox"===T.type},file:function(T){return T.nodeName.toLowerCase()==="input"&&"file"===T.type},password:function(T){return T.nodeName.toLowerCase()==="input"&&"password"===T.type},submit:function(U){var T=U.nodeName.toLowerCase();return(T==="input"||T==="button")&&"submit"===U.type},image:function(T){return T.nodeName.toLowerCase()==="input"&&"image"===T.type},reset:function(U){var T=U.nodeName.toLowerCase();return(T==="input"||T==="button")&&"reset"===U.type},button:function(U){var T=U.nodeName.toLowerCase();return T==="input"&&"button"===U.type||T==="button"},input:function(T){return(/input|select|textarea|button/i).test(T.nodeName)},focus:function(T){return T===T.ownerDocument.activeElement}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return U<T[3]-0},gt:function(V,U,T){return U>T[3]-0},nth:function(V,U,T){return T[3]-0===U},eq:function(V,U,T){return T[3]-0===U}},filter:{PSEUDO:function(V,a,Z,b){var T=a[1],U=H.filters[T];if(U){return U(V,Z,a,b)}else{if(T==="contains"){return(V.textContent||V.innerText||C.getText([V])||"").indexOf(a[3])>=0}else{if(T==="not"){var W=a[3];for(var Y=0,X=W.length;Y<X;Y++){if(W[Y]===V){return false}}return true}else{C.error(T)}}}},CHILD:function(T,W){var Z=W[1],U=T;switch(Z){case"only":case"first":while((U=U.previousSibling)){if(U.nodeType===1){return false}}if(Z==="first"){return true}U=T;case"last":while((U=U.nextSibling)){if(U.nodeType===1){return false}}return true;case"nth":var V=W[2],c=W[3];if(V===1&&c===0){return true}var Y=W[0],b=T.parentNode;if(b&&(b.sizcache!==Y||!T.nodeIndex)){var X=0;for(U=b.firstChild;U;U=U.nextSibling){if(U.nodeType===1){U.nodeIndex=++X}}b.sizcache=Y}var a=T.nodeIndex-c;if(V===0){return a===0}else{return(a%V===0&&a/V>=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName.toLowerCase()===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=H.attrHandle[V]?H.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!==U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=H.setFilters[T];if(W){return W(X,V,U,Y)}}}};var G=H.match.POS,B=function(U,T){return"\\"+(T-0+1)};for(var D in H.match){H.match[D]=new RegExp(H.match[D].source+(/(?![^\[]*\])(?![^\(]*\))/.source));H.leftMatch[D]=new RegExp(/(^(?:.|\r|\n)*?)/.source+H.match[D].source.replace(/\\(\d+)/g,B))}var I=function(U,T){U=Array.prototype.slice.call(U,0);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes,0)[0].nodeType}catch(R){I=function(X,W){var V=0,U=W||[];if(O.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var T=X.length;V<T;V++){U.push(X[V])}}else{for(;X[V];V++){U.push(X[V])}}}return U}}var N,J;if(document.documentElement.compareDocumentPosition){N=function(U,T){if(U===T){F=true;return 0}if(!U.compareDocumentPosition||!T.compareDocumentPosition){return U.compareDocumentPosition?-1:1}return U.compareDocumentPosition(T)&4?-1:1}}else{N=function(d,c){if(d===c){F=true;return 0}else{if(d.sourceIndex&&c.sourceIndex){return d.sourceIndex-c.sourceIndex}}var Y,U,V=[],T=[],X=d.parentNode,Z=c.parentNode,e=X;if(X===Z){return J(d,c)}else{if(!X){return -1}else{if(!Z){return 1}}}while(e){V.unshift(e);e=e.parentNode}e=Z;while(e){T.unshift(e);e=e.parentNode}Y=V.length;U=T.length;for(var W=0;W<Y&&W<U;W++){if(V[W]!==T[W]){return J(V[W],T[W])}}return W===Y?J(d,T[W],-1):J(V[W],c,1)};J=function(U,T,V){if(U===T){return V}var W=U.nextSibling;while(W){if(W===T){return -1}W=W.nextSibling}return 1}}C.getText=function(T){var U="",W;for(var V=0;T[V];V++){W=T[V];if(W.nodeType===3||W.nodeType===4){U+=W.nodeValue}else{if(W.nodeType!==8){U+=C.getText(W.childNodes)}}}return U};(function(){var U=document.createElement("div"),V="script"+(new Date()).getTime(),T=document.documentElement;U.innerHTML="<a name='"+V+"'/>";T.insertBefore(U,T.firstChild);if(document.getElementById(V)){H.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:undefined:[]}};H.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U);T=U=null})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){H.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="<a href='#'></a>";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){H.attrHandle.href=function(U){return U.getAttribute("href",2)}}T=null})();if(document.querySelectorAll){(function(){var T=C,W=document.createElement("div"),V="__sizzle__";W.innerHTML="<p class='TEST'></p>";if(W.querySelectorAll&&W.querySelectorAll(".TEST").length===0){return }C=function(h,Y,c,g){Y=Y||document;if(!g&&!C.isXML(Y)){var f=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(h);if(f&&(Y.nodeType===1||Y.nodeType===9)){if(f[1]){return I(Y.getElementsByTagName(h),c)}else{if(f[2]&&H.find.CLASS&&Y.getElementsByClassName){return I(Y.getElementsByClassName(f[2]),c)}}}if(Y.nodeType===9){if(h==="body"&&Y.body){return I([Y.body],c)}else{if(f&&f[3]){var b=Y.getElementById(f[3]);if(b&&b.parentNode){if(b.id===f[3]){return I([b],c)}}else{return I([],c)}}}try{return I(Y.querySelectorAll(h),c)}catch(d){}}else{if(Y.nodeType===1&&Y.nodeName.toLowerCase()!=="object"){var Z=Y,a=Y.getAttribute("id"),X=a||V,m=Y.parentNode,l=/^\s*[+~]/.test(h);if(!a){Y.setAttribute("id",X)}else{X=X.replace(/'/g,"\\$&")}if(l&&m){Y=Y.parentNode}try{if(!l||m){return I(Y.querySelectorAll("[id='"+X+"'] "+h),c)}}catch(e){}finally{if(!a){Z.removeAttribute("id")}}}}}return T(h,Y,c,g)};for(var U in T){C[U]=T[U]}W=null})()}(function(){var T=document.documentElement,V=T.matchesSelector||T.mozMatchesSelector||T.webkitMatchesSelector||T.msMatchesSelector;if(V){var X=!V.call(document.createElement("div"),"div"),U=false;try{V.call(document.documentElement,"[test!='']:sizzle")}catch(W){U=true}C.matchesSelector=function(Z,b){b=b.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!C.isXML(Z)){try{if(U||!H.match.PSEUDO.test(b)&&!/!=/.test(b)){var Y=V.call(Z,b);if(Y||!X||Z.document&&Z.document.nodeType!==11){return Y}}}catch(a){}}return C(b,null,null,[Z]).length>0}}})();(function(){var T=document.createElement("div");T.innerHTML="<div class='test e'></div><div class='test'></div>";if(!T.getElementsByClassName||T.getElementsByClassName("e").length===0){return }T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return }H.order.splice(1,0,"CLASS");H.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}};T=null})();function A(U,Z,Y,c,a,b){for(var W=0,V=c.length;W<V;W++){var T=c[W];if(T){var X=false;T=T[U];while(T){if(T.sizcache===Y){X=c[T.sizset];break}if(T.nodeType===1&&!b){T.sizcache=Y;T.sizset=W}if(T.nodeName.toLowerCase()===Z){X=T;break}T=T[U]}c[W]=X}}}function Q(U,Z,Y,c,a,b){for(var W=0,V=c.length;W<V;W++){var T=c[W];if(T){var X=false;T=T[U];while(T){if(T.sizcache===Y){X=c[T.sizset];break}if(T.nodeType===1){if(!b){T.sizcache=Y;T.sizset=W}if(typeof Z!=="string"){if(T===Z){X=true;break}}else{if(C.filter(Z,[T]).length>0){X=T;break}}}T=T[U]}c[W]=X}}}if(document.documentElement.contains){C.contains=function(U,T){return U!==T&&(U.contains?U.contains(T):true)}}else{if(document.documentElement.compareDocumentPosition){C.contains=function(U,T){return !!(U.compareDocumentPosition(T)&16)}}else{C.contains=function(){return false}}}C.isXML=function(T){var U=(T?T.ownerDocument||T:0).documentElement;return U?U.nodeName!=="HTML":false};var P=function(T,a){var Y,W=[],X="",V=a.nodeType?[a]:a;while((Y=H.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(H.match.PSEUDO,"")}T=H.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z<U;Z++){C(T,V[Z],W)}return C.filter(X,W)};window.AmSizzle=C})();(function(){var D=new Array();var C=window.AmLoggerAPI;var B=function(){};B.prototype.fire=function(E,F){if(!E){C.log("Skipping fire event , empty eventname");return }if(E.length<1){C.log("Skipping fire event , empty eventname");return }for(var G=0;G<D.length;G++){if(D[G].getName()===E){C.log("Executing fire event for: "+E);D[G].execute(F);break}}};B.prototype.listen=function(E,G){if(!E||!G){C.log("Skipping listen event , empty eventname");return }if(E.length<1){C.log("Skipping listen event , empty eventname");return }if(typeof G!="function"){C.log("Skipping listen event , hanlder is not a function");return }var H=null;for(var F=0;F<D.length;F++){if(D[F].getName()===E){H=D[F];break}}if(H==null){C.log("Event not found , creating new event to listen to: "+E);H=new A(E);D.push(H)}H.addHandler(G)};function A(E){this.name=E;this.eventHandlers=new Array()}A.prototype.getName=function(){return this.name};A.prototype.addHandler=function(E){this.eventHandlers.push(E)};A.prototype.execute=function(E){for(var F=0;F<this.eventHandlers.length;F++){try{this.eventHandlers[F](E)}catch(G){}}};if(window.AmEventsAPI){C.log("Overriding window.AmEventsAPI")}window.AmEventsAPI=new B()})();var DEFAULT_IMMEDIATE_INTERVAL=30;var PRE_PAGE_TAGGING=0;var FETCH_NODE_TAGGING=1;var PRE_TAGGING=2;var POST_TAGGING=3;var POST_PAGE_TAGGING=4;var am_shouldLeaveStyleAfterPostScript=true;function am_leaveStyleAfterPostScript(){if(!AmManager.isInplaceTaggingMode()){am_shouldLeaveStyleAfterPostScript=false}}function am_forceRemoveAmStyle(){am_shouldLeaveStyleAfterPostScript=true;window.AmInjectionAPI.removeStyles()}(function(){var logger=window.AmLoggerAPI;var eventApi=window.AmEventsAPI;var tags=new Array();var tagsDone=0;var API=function(){for(var name in this){var method=this[name];if(typeof method=="function"){this[name]=function(name,method){return function(){try{return method.apply(this,arguments)}catch(ex){window.AmErrorLoggerAPI.log("Failed in execution of method["+name+"]: ",ex);return false}}}(name,method)}}};API.handleDoneTag=function(){logger.log("Executing handleDoneTag");tagsDone++;if(tagsDone==tags.length){eventApi.fire("am:donetagging")}};API.handleDoneTagging=function(){logger.log("Executing handleDoneTagging");var postInjectionScripts=new Array();var styles=new Array();var i,j;for(i=0;i<tags.length;i++){for(j=0;j<tags[i].getScripts().length;j++){if(tags[i].getScripts()[j].runningMode==POST_PAGE_TAGGING){postInjectionScripts.push(tags[i].getScripts()[j].script)}}for(j=0;j<tags[i].getStyles().length;j++){styles.push(tags[i].getStyles()[j])}}API.executeScripts(postInjectionScripts);logger.log("Executing removeStyles method from doneTagging");window.AmInjectionAPI.removeStyles()};API.executeScripts=function(scripts){if(!scripts){logger.log("Skipping scripts , empty scripts");return }if(scripts.length<1){logger.log("Skipping scripts , empty scripts");return }logger.log("Executing scripts , number of scripts: "+scripts.length);for(var i=0;i<scripts.length;i++){try{eval(scripts[i])}catch(e){logger.log("Failed script execution: "+e.message);window.AmErrorLoggerAPI.log("Failed script execution: "+e.message,e)}}};API.executeStyles=function(styles){if(!styles){logger.log("Skipping styles , empty styles");return }if(styles.length<1){logger.log("Skipping styles , empty styles");return }logger.log("Executing styles , number of styles: "+styles.length);var head=document.getElementsByTagName("head")[0];for(var i=0;i<styles.length;i++){var style=document.createElement("style");style.type="text/css";var amuniqueid=styles[i].amuniqueid;style.setAttribute("amuniqueid",amuniqueid);style.setAttribute("id",amuniqueid);var rules=document.createTextNode(styles[i].style);if(style.styleSheet){style.styleSheet.cssText=rules.nodeValue}else{style.appendChild(rules)}head.appendChild(style)}};API.prototype.removeStyles=function(styles){if(!am_shouldLeaveStyleAfterPostScript){return }var styleIDsToRemove=new Array();logger.log("Kickoff Remove Styles");if(!styles){logger.log("remove styles called from done tagging and we have to make sure all styles have been removed");var head=document.getElementsByTagName("head")[0];styles=head.getElementsByTagName("style");for(var i=0;i<styles.length;i++){var amuniqueid=styles[i].getAttribute("amuniqueid");if(amuniqueid){styleIDsToRemove.push(amuniqueid)}}}else{logger.log("remove styles called from done tag");for(var i=0;i<styles.length;i++){styleIDsToRemove.push(styles[i]["amuniqueid"])}}if(styleIDsToRemove.length<1){logger.log("Skipping removing styles , empty styles");return }for(var i=0;i<styleIDsToRemove.length;i++){var amuniqueid=styleIDsToRemove[i];logger.log("trying to remove style: "+amuniqueid);if(amuniqueid){logger.log("trying to find style element for: "+amuniqueid);var styleToRemove=document.getElementById(amuniqueid);if(styleToRemove){logger.log("found and removed the style element: "+amuniqueid);styleToRemove.parentNode.removeChild(styleToRemove)}}}};API.prototype.registerSlots=function(slots){if(!slots||slots.length<1){logger.log("Skipped registration execution , empty slots");return }logger.log("Executing registration for "+slots.length+" slots");for(var i=0;i<slots.length;i++){logger.log("Registering slot: "+slots[i].slot.name);tags.push(new Tag(slots[i].slot))}};API.prototype.executeInjection=function(){if(!tags||tags.length<1){logger.log("Skipped Tag injection for due to empty tags");return }logger.log("Starting Tag injection for "+tags.length+" tags");var preInjectionScripts=new Array();var preInjectionCss=new Array();var i,j;for(i=0;i<tags.length;i++){for(j=0;j<tags[i].getScripts().length;j++){if(tags[i].getScripts()[j].runningMode==PRE_PAGE_TAGGING){preInjectionScripts.push(tags[i].getScripts()[j].script)}}for(j=0;j<tags[i].getStyles().length;j++){var amuniqueid="__"+Math.random();tags[i].getStyles()[j].amuniqueid=amuniqueid;preInjectionCss.push(tags[i].getStyles()[j])}}API.executeStyles(preInjectionCss);API.executeScripts(preInjectionScripts);for(i=0;i<tags.length;i++){tags[i].execute()}eventApi.listen("am:donetag",API.handleDoneTag);eventApi.listen("am:donetagging",API.handleDoneTagging)};API.prototype.execute=function(slots){var IE6=navigator.userAgent.indexOf("IE 6")>-1;if(IE6){logger.log("Cancled Visual Elements , not supported in IE6");return }this.registerSlots(slots);this.executeInjection()};window.AmInjectionAPI=new API()})();function Tag(A){this.slot=A;this.logger=window.AmLoggerAPI;this.eventApi=window.AmEventsAPI;this.timeoutId=-1;this.halt=false;this.tries=0;this.maxTries=A.maxTries||200;this.domDone=false;this.am_tags_innerWrap=["TD","TH","TD","DT","DD","LI"];for(var B in this){var C=this[B];if(typeof C=="function"){this[B]=function(D,E){return function(){try{return E.apply(this,arguments)}catch(F){window.AmErrorLoggerAPI.log("Failed in execution of method["+D+"]: ",F);return false}}}(B,C)}}}Tag.prototype.getStyles=function(){return this.slot.styles};Tag.prototype.getScripts=function(){return this.slot.scripts};Tag.prototype.scheduele=function(B){function A(C,D){return function(){D.apply(C,arguments)}}if(window.addEventListener){window.addEventListener("load",A(this,function(){this.logger.log("Marking DomDone on the tag: "+this.slot.name+" on dom loaded");this.markDomDone()}),false)}else{if(window.attachEvent){window.attachEvent("onload",A(this,function(){this.logger.log("Marking DomDone on the tag: "+this.slot.name+" on dom loaded");this.markDomDone()}))}}this.rescheduele(B)};Tag.prototype.rescheduele=function(B){function A(C,D){return function(){D.apply(C,arguments)}}if(B){this.timeoutId=setTimeout(A(this,function(){this.kickOff(true)}),DEFAULT_IMMEDIATE_INTERVAL);this.logger.log("Schedueled an immediate tag: "+this.slot.name)}else{if(window.addEventListener){window.addEventListener("load",A(this,this.kickOff),false)}else{if(window.attachEvent){window.attachEvent("onload",A(this,this.kickOff))}}this.logger.log("Schedueled a domloaded tag: "+this.slot.name)}};Tag.prototype.markDomDone=function(){this.domDone=true};Tag.prototype.kickOff=function(A){this.logger.log("Kickoff started for: "+this.slot.name);A=A&&(typeof A==="boolean");this.tries++;this.halt=this.halt||this.tries>=this.maxTries;if(this.halt){this.logger.log("Slot halted , Kickoff canceled for slot: "+this.slot.name+" firing donetag");this.eventApi.fire("am:donetag");return }else{this.halt=this.domDone}var D=window.AmSelectionAPI.getElementBySelector(this.slot.slotPath);if(!D){this.logger.log("Node not found for: "+this.slot.name+" immediate: "+A);if(A){this.rescheduele(true)}else{this.eventApi.fire("am:donetag")}return }var E=this.getScript(this.getScripts(),FETCH_NODE_TAGGING);if(E){D=this.executeScript(E)}if(!D){this.logger.log("Node not found after fetchElement for: "+this.slot.name+" immediate: "+A);if(A){this.rescheduele(true)}else{this.eventApi.fire("am:donetag")}return }this.injectTag(D,this.slot);var B=this.getScript(this.getScripts(),PRE_TAGGING);if(B){this.logger.log("Executing pretag for: "+this.slot.name);this.executeScript(B)}else{this.logger.log("Skipped executing pretag for: "+this.slot.name)}this.logger.log("Executing liveexperience for: "+this.slot.name);liveExperience(this.slot.name,true);var C=this.getScript(this.getScripts(),POST_TAGGING);if(C){this.logger.log("Executing posttag for: "+this.slot.name);this.executeScript(C)}else{this.logger.log("Skipped executing posttag for: "+this.slot.name)}this.logger.log("Executing removestyles for: "+this.slot.name);window.AmInjectionAPI.removeStyles(this.slot.styles);this.logger.log("Executing fire event donetag for slot: "+this.slot.name+" after execution");this.eventApi.fire("am:donetag")};Tag.prototype.executeScript=function(scriptStr){if(!scriptStr){this.logger.log("Skipping script , empty scripts");return }this.logger.log("Executing script: "+scriptStr);try{var slotStr=scriptStr;return eval(slotStr)}catch(e){this.logger.log("Failed script execution: "+e.message);window.AmErrorLoggerAPI.log("Failed script execution: "+e.message,e)}};Tag.prototype.injectTag=function(G,M){if(!G){this.logger.log("Skipping injection , node not found for slot: "+M.name+" with path: "+M.slotPath);return }var D=document.createElement("div");D.setAttribute("id",M.name);var B=parseInt(M.injectionMode);switch(B){case 0:this.logger.log("Wrapping node");var N=false;if(AmJS.inArray(G.tagName,this.am_tags_innerWrap)>-1){N=true}var J=AmUtil.getStyleProperty(G,"display");var F=AmUtil.getStyleProperty(G,"clear");var C=AmUtil.getStyleProperty(G,"cssFloat");var E=AmUtil.getStyleProperty(G,"position");if(E=="absolute"||E=="relative"){var O=AmUtil.getStyleProperty(G,"top")||null;var A=AmUtil.getStyleProperty(G,"right")||null;var K=AmUtil.getStyleProperty(G,"bottom")||null;var P=AmUtil.getStyleProperty(G,"left")||null;var H=AmUtil.getStyleProperty(G,"width")||null;var I=AmUtil.getStyleProperty(G,"height")||null}if(N){var L=G.innerHTML;G.innerHTML="";D.innerHTML=L;G.appendChild(D)}else{G.parentNode.insertBefore(D,G);D.appendChild(G)}D.style.display=J;D.style.clear=F;D.style.cssFloat=C;if(E=="absolute"||E=="relative"){D.style.position=E;if(H){D.style.width=H+"px"}if(I){D.style.height=I+"px"}if(O&&O!="auto"){D.style.top=O}if(A&&A!="auto"){D.style.right=A}if(K&&K!="auto"){D.style.bottom=K}if(P&&P!="auto"){D.style.left=P}if(!AmManager.isInplaceTaggingMode()){G.style.top=0;G.style.right=0;G.style.bottom=0;G.style.left=0}}break;case 1:this.logger.log("Inserting before");G.parentNode.insertBefore(D,G);break;case 2:this.logger.log("Inserting after");if(G.nextSibling){G.parentNode.insertBefore(D,G.nextSibling)}else{G.parentNode.appendChild(D)}break;case 3:this.logger.log("Inserting before");G.appendChild(D);break}};Tag.prototype.getScript=function(A,C){if(!A){return null}for(var B=0;B<A.length;B++){if(A[B].runningMode==C){return A[B].script}}return null};Tag.prototype.execute=function(){this.scheduele(this.slot.loadMode==1)};var amPageSummary={amPageSummary:{globalControl:"",selectedVirtualSlots:"",optimizations:[]}};var PageParams={addPageParams:function(expression){var expr="amDisplayedOptimization = "+expression;eval(expr);amPageSummary.amPageSummary.optimizations[amPageSummary.amPageSummary.optimizations.length]=amDisplayedOptimization},addGlobalControl:function(expression){var expr="globalControl = "+expression;eval(expr);amPageSummary.amPageSummary.globalControl=globalControl},setSelectedVirtualSlots:function(expression){var expr="selectedVirtualSlots = "+expression;eval(expr);amPageSummary.amPageSummary.selectedVirtualSlots=selectedVirtualSlots},getPageParams:function(){var A={globalControl:"",optimizations:[]};var C=amPageSummary.amPageSummary;A.globalControl=C.globalControl;var B=new AmHash();for(optCount=0;optCount<C.optimizations.length;optCount++){key=this.getOptimizationKey(C.optimizations[optCount]);if(!B.hasKey(key)){B.set(key,key);A.optimizations[A.optimizations.length]=C.optimizations[optCount]}}return A},getOptimizationKey:function(A){var B="";B+=A.optimizationId;for(iw=0;iw<A.weblets.length;iw++){B+=A.weblets[iw].webletId}return B},parsePageParams:function(D){var A="Global Control : "+D.globalControl.optimizationId+"  "+D.globalControl.optimizationName;var B="";if(D.globalControl.weblets){for(j=0;j<D.globalControl.weblets.length;j++){B+=D.globalControl.weblets[j].webletName+"  "+D.globalControl.weblets[j].webletId+"||"}}A+="  * "+B+"\n";for(i=0;i<D.optimizations.length;i++){var C="";for(j=0;j<D.optimizations[i].weblets.length;j++){C+=D.optimizations[i].weblets[j].webletName+"  "+D.optimizations[i].weblets[j].webletId+"||"}A+=D.optimizations[i].optimizationName+"   "+D.optimizations[i].optimizationId+"  "+C+"***"}return A},parseFullPageParams:function(C){var A="Global Control : "+C.globalControl.name+"  "+C.globalControl.id;var B="";if(C.globalControl.weblets){for(j=0;j<C.globalControl.weblets.length;j++){B+=C.globalControl.weblets[j].name+"  "+C.globalControl.weblets[j].id+"||"}}A+="  * "+B+"\n";for(i=0;i<C.optimizations.length;i++){var D="";for(j=0;j<C.optimizations[i].weblets.length;j++){D+=C.optimizations[i].weblets[j].name+"  "+C.optimizations[i].weblets[j].id+" SLOTS: ";for(k=0;k<C.optimizations[i].weblets[j].elements.length;k++){D+=C.optimizations[i].weblets[j].elements[k].name+","}D+="||"}var E="";for(j=0;j<C.optimizations[i].elements.length;j++){E+=C.optimizations[i].elements[j].name+"   "+C.optimizations[i].elements[j].weblet.id+"   "+C.optimizations[i].elements[j].weblet.name+"^^^^^"}A+=C.optimizations[i].name+"   "+C.optimizations[i].id+"  "+D+" ssss:  "+E+"***\n"}return A},amGetPageInventory:function(){var B=new AmHash();var A=new AmHash();for(i in AmContentManager.contents.items){var F=AmContentManager.contents.get(i);var E=B.get(F.testID);var D=A.get(F.testID+""+F.webletID);if(!E){E=new AmHash();B.set(F.testID,E)}if(!AmUtil.endsWith(F.slotName,".base_template")&&!AmUtil.endsWith(F.slotName,".product_template")){E.set(F.slotName,F.slotName);if(!D){D=new AmHash();A.set(F.testID+""+F.webletID,D)}D.set(F.slotName,F.slotName)}}var G={amPageInventory:{globalControl:"",optimizations:[]}};var C=this.getPageParams();G.amPageInventory.globalControl=this.cloneGlobalControl(C.globalControl);for(j=0;j<C.optimizations.length;j++){if(B.get(C.optimizations[j].optimizationId)){G.amPageInventory.optimizations[G.amPageInventory.optimizations.length]=this.cloneOptimization(C.optimizations[j],B,A)}}return G.amPageInventory},cloneGlobalControl:function(A){var B={id:A.optimizationId,name:A.optimizationName,weblets:[]};if(A.weblets){for(i=0;i<A.weblets.length;i++){B.weblets[B.weblets.length]={id:A.weblets[i].webletId,name:A.weblets[i].webletName}}}return B},cloneOptimization:function(F,C,B){var A={id:F.optimizationId,name:F.optimizationName,weblets:[],elements:[]};var D=new AmHash();for(i=0;i<F.weblets.length;i++){D.set(F.weblets[i].webletId,F.weblets[i].webletName);A.weblets[A.weblets.length]=this.createWeblet(F.weblets[i],B.get(F.optimizationId+""+F.weblets[i].webletId))}for(slotName in C.get(F.optimizationId).items){var E=AmContentManager.contents.get(slotName);A.elements[A.elements.length]=this.createElement(slotName,E.webletID,D.get(E.webletID))}return A},createElement:function(A,C,B){return{name:A,weblet:{id:C,name:B}}},createWeblet:function(C,B){var A={id:C.webletId,name:C.webletName,elements:[]};if(B){for(slotName in B.items){A.elements[A.elements.length]={name:slotName}}}return A}};var AmCookie={userID:"",visitID:0,profileID:"1",hitsCounter:0,timeStamp:0,serverID:"",version:-1,get:function(){return AmJSCookie.get(AmConstant.COOKIE_NAME)},save:function(A){AmJSCookie.set(AmConstant.COOKIE_NAME,A)}};function AmContent(A){this.slotName=A;this.testID;this.testType;this.webletID;this.egID;this.data=[];this.type;this.add=function(B){this.data.push(B)};this.getHTML=function(){var F="";if(this.testID&&this.webletID){var D=this.testID+"."+this.webletID;var E=AmResponse.results.get(D);if(E){F=E.egID}}var B="";for(var C=0;C<this.data.length;C++){B+=this.data[C]}B=AmUtil.convertAliases(B,F);return B}}function AmEvent(B,D,A,C){this.slotName=B;this.url=D;this.testID=A;this.webletID=C;this.send=function(){var E=this.testID+"."+this.webletID;var F=AmResponse.results.get(E);if(!F){F=AmResponse.productsRecom.get(E)}if(F){this.url=AmUtil.convertAliases(this.url,F.egID);var G=false;G=F.isRequest;this.url+="&iwr="+(G?"1":"0");this.url+=AmManager.getTimeStampParam();AmUtil.sendImageRequest(this.url,null)}}}var AmContentManager={contents:new AmHash(),events:new AmHash(),crossSiteEvents:new AmHash(),executedElementsSet:new AmHash(),amTags:function(A){},attachContent:function(D,F,G,C,E,A,B){var H=this.contents.get(D);if(H){return }H=new AmContent(D);H.add(F);if(G){H.type=G}if(C){H.testID=C}if(E){H.webletID=E}if(A){H.egID=A}if(B){H.testType=B}this.contents.set(D,H)},attachEvent:function(C,E,B,D){var A=this.events.get(C);if(!A){A=new AmEvent(C,E,B,D)}this.events.set(C,A)},attachCrossSiteEvent:function(D,B,C){var A=this.crossSiteEvents.get(B);if(!A){A=new AmEvent("",D,B,C)}this.crossSiteEvents.set(B,A)},execute:function(B,F,D){this.executedElementsSet.set(B,B);var C=this.contents.get(B);if(C){if(AmConstant.AM_CONTROL_EMPTY_CONTENT!=C.getHTML()){this.executeContent(C,D);var A=this.events.get(B);if(A){A.send()}A=this.crossSiteEvents.get(C.testID);if(A){A.send();this.crossSiteEvents.remove(C.testID)}}}else{if(F){if(AmManagerCommon.isTestServer()||AmManager.crossElementsSet.hasKey(B)){AmManager.serverRequest(AmConstant.SLOT_PPID,B,D);return }}else{if(AmConstant.SLOT_TOP!=B){var E="#"+B+"{display:inline;}";AmUtil.appendStyle(E)}}}if(D){AmContentManager.amTags(B)}},executeContent:function(D,G){var F=D.getHTML();if(G){var B=document.getElementById(D.slotName);if(B){F=this.removeWrapDiv(F,D.slotName);var H=/^\s*\<script|\<style/i;if(H.test(F)){F="<span style='display:none;'>&#160;</span>"+F}B.innerHTML=F;var K=B.getElementsByTagName("Script");if(K){for(var E=0;E<K.length;E++){var J=document.createElement("script");J.type="text/javascript";J.text=K[E].text;document.body.appendChild(J)}}}}else{if(document.getElementById(D.slotName)){var I=true}document.write(F);if(D.type==AmConstant.CONTENT_HIDE){var A="#"+D.slotName+"{display:none;}";AmUtil.appendStyle(A)}else{if(D.type==AmConstant.CONTENT_BLOCK){document.write("<noscript>");var C=D.testID;if(C=="77"||C=="48"||C=="126"||C=="56"){if(!I){document.write("</noscript>")}}}}}},removeWrapDiv:function(D,B){if(D){var C='<div id="'+B+'">';var E=D.indexOf(C);var A=D.lastIndexOf("</div>");if(E!=-1&&E<A){D=D.substring(E+C.length,A)}}return D},getContent:function(A){return this.contents.get(A)},getTestContentWeblets:function(B,E){var C=[];if(B&&this.contents&&E){var F;var D=E.split(",");if(D){for(var A=0;A<D.length;A++){F=this.getContent(D[A]);if(F&&B==F.testID){C.push(F.webletID)}}}}return C}};var AmResponse={results:new AmHash(),productsRecom:new AmHash(),addResult:function(B){var A=B.testID+"."+B.webletID;this.results.set(A,B)},addProductRecom:function(B){var A=B.testID+"."+B.webletID;this.productsRecom.set(A,B)},set:function(key,value){eval("this."+key+"='"+value+"';")},setCookieParams:function(E,G,F,A,D,C,B){AmCookie.userID=E;AmCookie.visitID=G;AmCookie.profileID=F;AmCookie.hitsCounter=A;AmCookie.timeStamp=D;AmCookie.serverID=C;if(B){AmCookie.version=B}}};function AmResponseResult(E,D,G,B,C,F,A,H){this.testType=E;this.testID=D;this.webletID=G;this.egID=B;this.plID=C;this.cookieExp=F;this.commands=A;this.isRequest=H}function AmResponseProductRecom(B,A,D,E,C){this.testID=B;this.egID=A;this.amadesaIDs=D;this.isRequest=E;this.webletID=C}var AmResponseManager={execute:function(B){AmManagerCommon.clearRequestTimeout();this.sendStubCallToCacheSelectedServer();if(AmConstant.SLOT_TOP==AmResponse.slotName&&window.amPid&&window.amProductId){var A=AmManager.serverRequestProducts;if(AmResponse.secure&&AmResponse.secure=="true"){A=AmManager.serverRequestSecureProducts}AmUtil.attachEvent(window,"load",A)}if(!AmManager.isInplaceTaggingMode()){AmCookie.save(AmResponse.cookie)}for(var D in AmResponse.productsRecom.items){var C=AmResponse.productsRecom.items[D];if(C instanceof AmResponseProductRecom){this.executeProductRecom(C)}}AmContentManager.execute(AmResponse.slotName,false,B);AmResponse.productsRecom=new AmHash();if(AmConstant.SLOT_TOP==AmResponse.slotName){this.callInjectionEngine()}},sendStubCallToCacheSelectedServer:function(){if(AmConstant.SLOT_TOP==AmResponse.slotName){var A=AmManager.getImageRequestURL();if(!AmManager.AM_DISABLE_AMADESA){AmUtil.sendImageRequest(A,null)}}},callInjectionEngine:function(){if(window.AmInjectionAPI&&window.AmInjectionAPI.execute){var A=amPageSummary.amPageSummary.selectedVirtualSlots;window.AmInjectionAPI.execute(A)}},executeProductRecom:function(oProductRecom){var oContentTemplateBase=AmContentManager.contents.get(AmResponse.slotName+AmConstant.PRODUCT_BASE_TEMPLATE);var oContentTemplateProduct=AmContentManager.contents.get(AmResponse.slotName+AmConstant.PRODUCT_TEMPLATE);var strHTMLTemplateBase="";var strHTMLTemplateProduct="";var arrProducts=[];var templateBaseTestId;var templateBaseWebletId;var templateBaseType;if(oContentTemplateBase){strHTMLTemplateBase=oContentTemplateBase.getHTML();templateBaseTestId=oContentTemplateBase.testID;templateBaseWebletId=oContentTemplateBase.webletID;templateBaseType=oContentTemplateBase.type}else{strHTMLTemplateBase=eval("window.testProductBaseTemplate_"+oProductRecom.testID)}if(oContentTemplateProduct){strHTMLTemplateProduct=oContentTemplateProduct.getHTML()}else{strHTMLTemplateProduct=eval("window.testProductTemplate_"+oProductRecom.testID)}for(var i=0;i<oProductRecom.amadesaIDs.length;i++){var oProduct=eval("window.product_"+oProductRecom.amadesaIDs[i]);if(oProduct){arrProducts.push(oProduct)}}var strFullRecomHTML=strHTMLTemplateBase?strHTMLTemplateBase:"";if(strHTMLTemplateProduct&&strHTMLTemplateBase){var strProductTemplates="";for(var i=0;i<arrProducts.length;i++){var oProduct=arrProducts[i];var strProductTemplate=strHTMLTemplateProduct;strProductTemplate=strProductTemplate.replace(/\$prodcut_id/g,oProduct.id);strProductTemplate=strProductTemplate.replace(/\$product_id/g,oProduct.id);strProductTemplate=strProductTemplate.replace(/\$product_index/g,i);strProductTemplate=strProductTemplate.replace(/\$product_title/g,oProduct.title);strProductTemplate=strProductTemplate.replace(/\$product_description/g,oProduct.description);strProductTemplate=strProductTemplate.replace(/\$product_image/g,oProduct.image);strProductTemplate=strProductTemplate.replace(/\$product_link/g,this.getProductRecomClickURL(oProductRecom.testID,oProductRecom.egID,oProduct.id,oProduct.link,templateBaseWebletId));strProductTemplate=AmPR.executeProductCurrency(oProduct,strProductTemplate);strProductTemplates+=strProductTemplate}strFullRecomHTML=strHTMLTemplateBase.replace(/\$recommendation_products/g,strProductTemplates)}AmContentManager.attachContent(AmResponse.slotName,strFullRecomHTML,templateBaseType,templateBaseTestId,templateBaseWebletId)},getProductRecomClickURL:function(C,A,F,E,D){var G="";var B="";if(D&&D!=""&&D!="0"){G="&evt=8,w,"+D;B=D}else{G="&evt=8,t,"+C}return AmConstant.Alias.COUNTER_URL+"pid="+amPid+AmManager.getUIDParam()+AmManager.getTimeStampParam()+"&vsid="+AmConstant.Alias.VISIT_ID+"&hc="+AmConstant.Alias.HITS_COUNTER+"&prid="+AmConstant.Alias.PROFILE_ID+"&tid="+C+"&ttype="+AmConstant.TestType.RECOMMENDATION+"&egid="+A+"&wid="+B+G+"&pctid="+F+"&red="+E}};function AmCurrencyProduct(A){this.productId="";this.displayPrice="";this.listPrice="";this._parse=function(B,C){if(AmUtil.isNumber(B)){this.displayPrice=B}else{this.displayPrice=AmUtil.getQueryStringHash(B)}if(AmUtil.isNumber(C)){this.listPrice=C}else{this.listPrice=AmUtil.getQueryStringHash(C)}};this._init=function(B){this.productId=B.id;this._parse(B.displayPrice,B.listPrice)};this._init(A)}var AmPR={CURRENCIES:{USD:"&#36;",EUR:"&#128;",GBP:"&#163;",CAD:"&#36;",NIS:"&#8362;"},RECOM_CURRENCY_VAR:"amRecomCurrency",executeProductCurrency:function(B,C){var A=new AmCurrencyProduct(B);C=this.replaceTemplate(C,A,"display",true);C=this.replaceTemplate(C,A,"list",true);C=this.replaceTemplate(C,null,"",false);C=C.replace(/\$product_display_price/g,this.getProductPrice(A,"","display",true));C=C.replace(/\$product_list_price/g,this.getProductPrice(A,"","list",true));return C},replaceTemplate:function(A,H,E,C){var F="";var D="";if(C){D="\\$product_"+E+"_price"}else{D="\\$product_price_symbol"}F=D+"\\[([^\\]]*)\\]";var B=new RegExp(F,"g");var G=B.exec(A);while(G){var I="";if(C){I=this.getProductPrice(H,G[1],E,false)}else{I=this.getProductPriceSymbol(G[1])}A=A.replace(G[0],I);G=B.exec(A)}return A},getCurrency:function(currency){if(currency==this.RECOM_CURRENCY_VAR){currency=eval("window."+this.RECOM_CURRENCY_VAR)}return currency},getProductPrice:function(currencyProduct,currency,identifier,basePrice){var retVal="";currency=this.getCurrency(currency);var price=eval("currencyProduct."+identifier+"Price");if(AmUtil.isNumber(price)){if(basePrice){retVal=price}}else{if(price.hasKey(currency)){retVal=price.get(currency)}}return retVal},getProductPriceSymbol:function(currency){currency=this.getCurrency(currency);if(currency){currency=eval("AmPR.CURRENCIES."+currency)}if(!currency){currency=""}return currency}};var AmInplaceSubscription={unsubscribeSites:function(A){var B=AmInplaceSubscription.getUnsubscribeSitesURL(A);AmUtil.createAndAppendScript(B)},unsubscribeAll:function(){var A=AmInplaceSubscription.getUnsubscribeAllURL();AmUtil.createAndAppendScript(A)},subscribeSites:function(A){var B=AmInplaceSubscription.getSubscribeSitesURL(A);AmUtil.createAndAppendScript(B)},subscribeAll:function(){var A=AmInplaceSubscription.getSubscribeAllURL();AmUtil.createAndAppendScript(A)},getUnsubscribeSitesURL:function(A){return AmUtil.getProtocol()+"//"+AmConstant.DOMAIN+AmConstant.INPLACE_SUBSCRIPTION_REST_UNSUBSCRIBE+AmConstant.INPLACE_SITE_SUBSCRIPTION_REST+(A?A:window.amPid)},getSubscribeSitesURL:function(A){return AmUtil.getProtocol()+"//"+AmConstant.DOMAIN+AmConstant.INPLACE_SUBSCRIPTION_REST_SUBSCRIBE+AmConstant.INPLACE_SITE_SUBSCRIPTION_REST+(A?A:window.amPid)},getSubscribeAllURL:function(){return AmUtil.getProtocol()+"//"+AmConstant.DOMAIN+AmConstant.INPLACE_SUBSCRIPTION_REST_SUBSCRIBE},getUnsubscribeAllURL:function(){return AmUtil.getProtocol()+"//"+AmConstant.DOMAIN+AmConstant.INPLACE_SUBSCRIPTION_REST_UNSUBSCRIBE}};function liveExperience(A,B){if(!AmManager.checkFBFromEntrenceURL()){if(!AmManager.checkGomezFromEntrenceURL()){AmContentManager.execute(A,true,B)}}}function amCrossDomain(A){var C=A;var B=AmCookie.get();if(A&&B){C+=(A.indexOf("&")==-1&&A.indexOf("?")==-1)?"?":"&";C+=AmConstant.COOKIE_NAME+"="+B}if(C.length>AmConstant.MAX_COOKIE_LENGTH){return A}else{return C}}function amReportCompletion(B,A){if(AmManager.checkGomezFromEntrenceURL()||AmManager.checkFBFromEntrenceURL()||AmManager.AM_DISABLE_AMADESA){if(A){A()}return }if(window.amUseGeoLocation){AmGeoManager.amReportCompletionMode=true;AmGeoManager.amGetSiteProperties(function(){amContinueReportCompletion(window.amPPid,window.amReportPageCallBackFunction)})}else{amContinueReportCompletion(B,A,true)}}function amContinueReportCompletion(D,C,B){if(!AmGeoManager.amReportCompletionMode&&!B){return }AmGeoManager.amReportCompletionMode=false;if(D){var A=AmManager.getRequestURL(D,AmConstant.SLOT_TOP);AmUtil.sendImageRequest(A,C)}}function amReportClick(A,C){if(AmManager.checkGomezFromEntrenceURL()||AmManager.checkFBFromEntrenceURL()||AmManager.AM_DISABLE_AMADESA){if(C){C()}return }if(amPid&&A){var B=AmManager.getClickRequestURL(A);AmUtil.sendImageRequest(B,C)}}function amBtContentClicked(F,B,G){AmManager.amBtContentClickedCallBackFunction=B;var D="";if(G&&F){var C=AmUtil.getFirstResultOfRegExp(F,"&tid=([0-9]+)");if(C){0;var A=AmUtil.getFirstResultOfRegExp(F,"&evt=8,w,([0-9]+)");var I=AmContentManager.getTestContentWeblets(C,G);if(I){for(var E=0;E<I.length;E++){if(!A||A!=I[E]){D=D+"&evt=8,w,"+I[E]}}}}}var H=document.createElement("script");H.type="text/javascript";H.src=F+D+"&btclck=1&ck="+AmCookie.get()+"&us="+(window.amCheckThirdParty?"2":AmJSCookie.getCookieEnabled());document.body.appendChild(H)}var AmGeoManager={logger:window.AmLoggerAPI,suspenseScriptsCounter:0,geoLocationStartTime:null,geoLocationWaitingTime:null,amReportCompletionMode:false,callbackFunc:null,amReportCompletionModeTimeout:null,amProcessSuspenseResponse:function(){AmManagerCommon.clearRequestTimeout();if(document.getElementById("amSuspenseScript_"+(this.suspenseScriptsCounter))){var A=document.getElementById("amSuspenseScript_"+(this.suspenseScriptsCounter));A.parentNode.removeChild(A)}if(!window.amGeoLocationData){this.suspenseScriptsCounter++;var C=new Date().getTime();if(C-this.geoLocationStartTime>this.geoLocationWaitingTime){this.reportAndLogGeoError("33","GeoLocation - failed: wait timeout is over, waited: "+this.geoLocationWaitingTime+"ms.");this.callbackFunc();return }var F="";if("https:"==AmUtil.getProtocol()){F="https://"+AmConstant.ETERN_DOMAIN}else{F="http://"+AmConstant.ETERN_DOMAIN}F+="/intermitter?t="+((amGetQueryVariable("amT")>-1)?amGetQueryVariable("amT"):0.2);F+="&ts="+new Date().getTime();if(!AmJSCookie.get(AmConstant.TIME_OUT_COOKIE_NAME)){AmManagerCommon.setRequestTimeout();if(this.amReportCompletionMode){var E=document.createElement("script");E.src=F;E.id="amSuspenseScript_"+this.suspenseScriptsCounter;document.body.appendChild(E)}else{document.write(AmUtil.getScriptTag(F,"amSuspenseScript_"+this.suspenseScriptsCounter))}}}else{var B=window.AmGeoLocationDataHandler.getData();if(B&&!B.error){var D="geo-location: device: "+amMobileUserAgentDetection.amIsSmartPhone?"Smartphone":amMobileUserAgentDetection.amIsTablet?"Tablet":"not defined";D+=" / latitude: "+((amForceGeoData&&amForceGeoData.lat)?amForceGeoData.lat:(B.coords.latitude));D+=" / longitude: "+((amForceGeoData&&amForceGeoData.lon)?amForceGeoData.lon:(B.coords.longitude));this.logger.log("GeoLocation: "+D)}this.callbackFunc()}},amSetSiteProperties:function(){AmManagerCommon.clearRequestTimeout();if(window.amSiteProperties&&window.amSiteProperties.advancedSiteProperties&&window.amSiteProperties.advancedSiteProperties.geoFetching){window.amAdvancedSiteProperties=window.amSiteProperties.advancedSiteProperties.geoFetching;if(!this.checkSitePropertiesVsDevice()){this.reportAndLogGeoError("66","GeoLocation - failed: site properties Vs device conflict");this.callbackFunc()}else{AmGeoLocation.init();this.amProcessSuspenseResponse()}}else{this.reportAndLogGeoError("44","GeoLocation - failed: geo location on site properties is prevented or not defined");this.callbackFunc()}},checkIfSitePropertiesHasGeoFetchingData:function(){if(window.amSiteProperties&&window.amSiteProperties.advancedSiteProperties&&window.amSiteProperties.advancedSiteProperties.geoFetching){return true}return false},checkSitePropertiesVsDevice:function(){return(this.checkDeviceAndIfSiteAllowSmartphone()&&this.checkDeviceAndIfSiteAllowTablet())},checkDeviceAndIfSiteAllowSmartphone:function(){return(!amMobileUserAgentDetection.amIsSmartPhone)||(window.amAdvancedSiteProperties.smartphone&&window.amAdvancedSiteProperties.smartphone.toString().toLowerCase()=="true"&&amMobileUserAgentDetection.amIsSmartPhone)},checkDeviceAndIfSiteAllowTablet:function(){return(!amMobileUserAgentDetection.amIsTablet)||(window.amAdvancedSiteProperties.tablet&&window.amAdvancedSiteProperties.tablet.toString().toLowerCase()=="true"&&amMobileUserAgentDetection.amIsTablet)},setGeoLocationStartTime:function(){this.geoLocationStartTime=new Date().getTime()},setGeoLocationWaitingTime:function(A){this.geoLocationWaitingTime=A},amGetSiteProperties:function(A){this.callbackFunc=A;AmManagerCommon.clearRequestTimeout();var C=AmUtil.getProtocol()+"//"+AmUtil.getDomain()+AmUtil.getSiteProps().replace(/{siteId}/g,window.amPid);if(this.amReportCompletionMode){this.amReportCompletionModeSetTimeout();var B=document.createElement("script");B.src=C;document.body.appendChild(B)}else{AmManagerCommon.checkCookieSetTimeoutAndWriteScript(C)}},amReportCompletionModeSetTimeout:function(){this.amReportCompletionModeTimeout=setTimeout(function(){if(!window.amSiteProperties){this.reportAndLogGeoError("88","GeoLocation - failed: on append script");this.callbackFunc()}},window.amJSTimeout?window.amJSTimeout:AmConstant.TIME_OUT_TOLLERANCE)},reportAndLogGeoError:function(A,B){this.logger.log(B);AmGeoLocationDataHandler.set({error:{code:A,desc:B}},"failed")}};var AmManagerCommon={timeOutCall:false,isTestServer:function(){return this.checkURLTestServer()||this.checkCookieTestServer()},checkURLTestServer:function(){return window.location.href.indexOf(AmConstant.TEST_SERVER)!=-1},checkCookieTestServer:function(){return AmJSCookie.get(AmConstant.COOKIE_NAME_TEST_SERVER)=="1"},setRequestTimeout:function(A){if(this.isTestServer()){return }if(this.timeOutCall){this.clearRequestTimeout()}if(AmJSCookie.get(AmConstant.IGNORE_TIME_OUT_COOKIE_NAME)==="true"){return }this.timeOutCall=setTimeout(function(){AmJSCookie.set(AmConstant.TIME_OUT_COOKIE_NAME,"true",true);location.reload(false)},window.amJSTimeout?window.amJSTimeout:AmConstant.TIME_OUT_TOLLERANCE)},clearRequestTimeout:function(){if(this.timeOutCall){clearTimeout(this.timeOutCall)}},setIgnoreTimeoutCookie:function(){var A=this.checkURLIgnoreTimeout();if(A==="true"){AmJSCookie.set(AmConstant.IGNORE_TIME_OUT_COOKIE_NAME,"true",false,true);AmJSCookie.deleteCookie(AmConstant.TIME_OUT_COOKIE_NAME,"false",true)}else{if(A==="false"){AmJSCookie.deleteCookie(AmConstant.IGNORE_TIME_OUT_COOKIE_NAME,"false",true)}}},checkURLIgnoreTimeout:function(){return AmUtil.getExactQueryStringParam("ignoreTimeout")},checkCookieSetTimeoutAndWriteScript:function(A){if(!AmJSCookie.get(AmConstant.TIME_OUT_COOKIE_NAME)){AmManagerCommon.setRequestTimeout();document.write(AmUtil.getScriptTag(A))}}};var AmManager={exelateTimeOutCall:false,bodyStyleOverflow:"",refreshDivsInsertionTime:-1,amBtContentClickedCallBackFunction:"",crossElementsSet:new AmHash(),AM_DISABLE_AMADESA:false,shouldDisableAmadesa:function(){var A=amGetQueryVariable(AmConstant.AM_DISABLE_AMADESA_COOKIE);if(A.toString().toLowerCase()=="true"){return this.setIsDisableAmadesa(true)}else{if(A.toString().toLowerCase()!="false"){if(typeof window.amDisableAmadesa!="undefined"&&window.amDisableAmadesa.toString().toLowerCase()=="true"){return this.setIsDisableAmadesa(true)}else{if(typeof window.amDisableAmadesa=="undefined"){if(AmJSCookie.get(AmConstant.AM_DISABLE_AMADESA_COOKIE)&&AmJSCookie.get(AmConstant.AM_DISABLE_AMADESA_COOKIE).toString()=="true"){return this.setDisableAmadesaParam(true)}else{if(typeof AmJSCookie.get(AmConstant.AM_DISABLE_AMADESA_COOKIE)=="undefined"){return this.setDisableAmadesaParam(false)}}}}return this.setDisableAmadesaParam(false)}}return this.setIsDisableAmadesa(false)},setDisableAmadesaParam:function(A){AmManager.AM_DISABLE_AMADESA=A;return A},setIsDisableAmadesa:function(A){AmJSCookie.set(AmConstant.AM_DISABLE_AMADESA_COOKIE,A);return AmManager.setDisableAmadesaParam(A)},init:function(){if(this.shouldDisableAmadesa()){return }if(window.amDisableInit&&window.amDisableInit===true){if(window.amCallReportPage&&window.amCallReportPage===true){amReportCompletion(window.amPPid,window.amReportPageCallBackFunction)}return }if(this.isInplaceTaggingMode()){this.callInplaceTaggingMode();return }if(this.checkGomezFromEntrenceURL()||AmManager.checkFBFromEntrenceURL()){return }this.setTestLiveServerCookie();AmManagerCommon.setIgnoreTimeoutCookie();if(AmManagerCommon.isTestServer()&&window.amPid&&window.amPid!="220"){this.loadRefreshTestServerDivs()}else{if(window.amCheckThirdParty&&window.amPid){this.checkThirdPartyRequest()}else{if(window.amUseGeoLocation){AmGeoManager.amGetSiteProperties(function(){AmManager.topCall()})}else{this.topCall()}}}},callBtCallBackFunc:function(){if(this.amBtContentClickedCallBackFunction){this.amBtContentClickedCallBackFunction()}},topCall:function(){if(AmManagerCommon.isTestServer()){this.clearRefreshTestServerDivs()}if(window.amPid){this.callExelateAndServer()}},addCrossSiteElements:function(agregatedEllemnts){var expr="elementsArr="+agregatedEllemnts;eval(expr);for(elCount=0;elCount<elementsArr.length;elCount++){this.crossElementsSet.set(elementsArr[elCount],elementsArr[elCount])}},setExelateAmParams:function(A){if(A&&A!="true"){window.amParams=window.amParams?(window.amParams+"&"+A):A}},callExelateAndServer:function(){var B=true;if(window.amPid=="161"){if(!document.domain||(document.domain.indexOf("bottomlinesecrets.com")==-1)){var A=AmJSCookie.get(AmConstant.EXELATE_COOKIE_NAME);if(!A){this.exelateTimeOutCall=setTimeout(function(){AmManager.saveExelateContent();location.reload(false)},window.amJSTimeout?window.amJSTimeout:AmConstant.TIME_OUT_TOLLERANCE);B=false;document.write(AmUtil.getScriptTag("http://load.exelator.com/load/?p=104&g=030&j=j"))}else{this.setExelateAmParams(A)}}}if(B){this.serverRequest()}},saveExelateContent:function(){var A=window.amExternalData?window.amExternalData:"true";var B=new Date();B.setDate(B.getDate()+1);AmJSCookie.setWithExpiration(AmConstant.EXELATE_COOKIE_NAME,A,B.toGMTString());AmManager.setExelateAmParams(A)},checkGomezFromEntrenceURL:function(){var B=false;var A=window.location.href;if(A&&(A.indexOf("Gomez=true"))!=-1){B=true}return B},checkFBFromEntrenceURL:function(){var A=false;var B=window.location.href;if(B&&(B.indexOf("fb_xd_fragment"))!=-1){A=true}return A},checkThirdPartyRequest:function(){var A=AmUtil.getProtocol()+"//"+AmUtil.getDomain()+AmUtil.getAppName()+"?proto="+AmUtil.getProtocolType()+"&pid="+amPid+"&chtpc=true";AmManagerCommon.checkCookieSetTimeoutAndWriteScript(A)},loadRefreshTestServerDivs:function(){var A='<script language="javascript">AmManager.checkRefreshTestServerAppsRequest();<\/script>';document.write(A)},onResizeRefreshTestServerDivs:function(){if(document.getElementById("amTestServerAppsRefreshMessageText")){if(Math.round(document.body.clientHeight/2)>150){document.getElementById("amTestServerAppsRefreshMessageText").style.top=Math.round(document.body.clientHeight/2)-150+"px"}else{document.getElementById("amTestServerAppsRefreshMessageText").style.top="0px"}if(Math.round(document.body.clientWidth/2)>400){document.getElementById("amTestServerAppsRefreshMessageText").style.left=Math.round(document.body.clientWidth/2)-400+"px"}else{document.getElementById("amTestServerAppsRefreshMessageText").style.left="0px"}}},notifyTestEnvFailed:function(){var A=document.getElementById("holdForTestEnvMessage");if(!A){return }A.innerHTML="An error has occurred while generating your test content. Please contact support@amadesa.com"},buildRefreshTestServerDivs:function(){var B="#amTestServerAppsRefreshBackground {background-color: white;opacity: 0.3;filter: alpha(opacity=30);width: 100%;height: 100%; position: absolute;top: 0px;left: 0px;}#amTestServerAppsRefreshMessageText {background-color: white ;border-style:solid;border-width:2px; border-color: #026899; position: absolute;top: 0px;left: 0px;}";AmUtil.appendStyle(B);document.write('<div id="amTestServerAppsRefreshBackground">&nbsp;</div>');var C='<div id="amTestServerAppsRefreshMessageText" style="text-align: center; width: 800px ;height: 200px;"><div style="margin-top: 50px;"><span style="color: #026899; font-family:verdana; font-size: 22px; font-weight: normal; text-decoration: none; vertical-align: middle;">You are viewing an Amadesa Test Link</span></div><div style="margin-top: 20px;margin-bottom: 20px;"><span id="holdForTestEnvMessage" style="color: #3D3D3D; font-family:verdana; font-size: 16px; font-weight: normal; line-height: 17px;">We are generating the required files for your test. This may take several minutes.<br/>Once the test is ready, you will be redirected to the page.</span></div></div>';document.write(C);var A=new Date();AmManager.refreshDivsInsertionTime=A.getTime()},placeRefreshTestServerDivs:function(){this.onResizeRefreshTestServerDivs();if(document.getElementById("amTestServerAppsRefreshMessageText")){AmUtil.attachEvent(window,"resize",AmManager.onResizeRefreshTestServerDivs);AmManager.bodyStyleOverflow=document.body.style.overflow;document.body.style.overflow="hidden"}},clearRefreshTestServerDivs:function(){this.waitingForRefreshDivsRemoval();var A=document.getElementById("amTestServerAppsRefreshBackground");this.removeRefreshTestServerDiv(A);A=document.getElementById("amTestServerAppsRefreshMessageText");this.removeRefreshTestServerDiv(A);document.body.style.overflow=AmManager.bodyStyleOverflow},waitingForRefreshDivsRemoval:function(){if(AmManager.refreshDivsInsertionTime>-1){var A;var B=true;while(B){A=new Date().getTime();if((A-AmManager.refreshDivsInsertionTime)>AmConstant.AM_TEST_APP_REFRESH_DIVS_DISPLAY_TIME){B=false;AmManager.refreshDivsInsertionTime=-1}}}},removeRefreshTestServerDiv:function(A){if(A){if(A.removeNode){A.removeNode(true)}else{if(A.parentNode&&A.parentNode.removeChild){A.parentNode.removeChild(A)}else{A.style.display="none"}}}},checkRefreshTestServerAppsRequest:function(){var A=this.buildRefreshTestServerAppsRequest(AmConstant.DIRECT_APPS_CHECK_REFRESH_COMMAND_NAME);document.write(AmUtil.getScriptTag(A))},refreshTestServerAppsRequest:function(B,C){if(B==AmConstant.AM_TEST_APP_REFRESH_REQUIRED){this.buildRefreshTestServerDivs();this.placeRefreshTestServerDivs();var D=this.buildRefreshTestServerAppsRequest(AmConstant.DIRECT_APPS_REFRESH_COMMAND_NAME);document.write(AmUtil.getScriptTag(D))}else{if(B==AmConstant.AM_TEST_APP_HOLD_REQUIRED){if(!this.initialHoldTime){this.initialHoldTime=new Date().getTime();if(!document.getElementById("amTestServerAppsRefreshMessageText")){this.buildRefreshTestServerDivs();this.placeRefreshTestServerDivs()}}C=C||0;var A=parseInt(C)>=AmConstant.AM_TEST_APP_HOLD_COUNT_TOLLERANCE;if(A){this.notifyTestEnvFailed();return }AmManager.sleep(AmConstant.AM_TEST_APP_HOLD_TIME_OUT_INTERVAL);var D=AmManager.buildRefreshTestServerAppsRequest(AmConstant.DIRECT_APPS_CHECK_HOLD_COMMAND_NAME,C);document.write(AmUtil.getScriptTag(D))}else{this.topCall()}}},sleep:function(A){if(!A){return }var B=new Date().getTime();var C;while(C=new Date().getTime()){if(B+A<C){break}}},buildRefreshTestServerAppsRequest:function(A,F){var D=window.location.href;var C="";if(D){var B=D.indexOf("amtestid=");if(B!=-1){var E=D.indexOf("&",B);E=E==-1?D.length:E;C="&testid="+D.substring(B+9,E)}}F=(F?("&cmdCount="+F):"");return AmConstant.PROTOCOL_HTTPS+"//"+AmConstant.ADMIN_DOMAIN+AmConstant.DIRECT_APPS_REFRESH_NAME+"?commandId="+A+"&pid="+window.amPid+F+C+"&ts="+AmUtil.getRandom()},setTestLiveServerCookie:function(){if(AmManagerCommon.checkURLTestServer()){AmJSCookie.set(AmConstant.COOKIE_NAME_TEST_SERVER,"1",true,true)}if(window.location.href.indexOf(AmConstant.LIVE_SERVER)!=-1){AmJSCookie.set(AmConstant.COOKIE_NAME_TEST_SERVER,"",true)}},getTestServerParam:function(){return AmManagerCommon.checkCookieTestServer()?"&"+AmConstant.TEST_SERVER+"="+AmConstant.TEST_SERVER:""},getAmDebugParam:function(){return window.location.href.indexOf(AmConstant.AM_DEBUG)!=-1?"&"+AmConstant.AM_DEBUG+"=true":""},getUserIDAndServerIDAsArray:function(C){var E=C?C:AmCookie.get();var H=new Array();var D="";var B="";if(E){var G=E.split("@");var F=G[0];var A=F.split(",");D=A[0];if(A.length>5&&A[1]&&A[1]!=""){B=A[1]}}else{D=AmCookie.userID;B=AmCookie.serverID}H[AmConstant.AM_UID_ARRAY_USER_ID]=D?D:"";H[AmConstant.AM_UID_ARRAY_SERVER_ID]=B?B:"";return H},getUserIDServerIDValue:function(A){var B=this.getUserIDAndServerIDAsArray(A);return B[AmConstant.AM_UID_ARRAY_SERVER_ID]?B[AmConstant.AM_UID_ARRAY_USER_ID]+"."+B[AmConstant.AM_UID_ARRAY_SERVER_ID]:B[AmConstant.AM_UID_ARRAY_USER_ID]},getUIDParam:function(A){return"&uid="+this.getUserIDServerIDValue(A)},getTimeStampParam:function(){return"&ts="+AmCookie.timeStamp},getFirstCategory:function(){var A=window.amCategory;if(A){var B=A.indexOf(",");A=B==-1?A:A.substring(0,B)}return A},getCategoryStr:function(){var B="";if(window.amCategory){B=window.amCategory;if(B.length>AmConstant.MAX_CATEGORIE_LENGTH){var A=B.split(AmConstant.CATEGORIE_SEPARATOR);for(i=0;i<A.length;i++){if((B+A[i])<=AmConstant.MAX_CATEGORIE_LENGTH){B+=A[i]}}}B=window.encodeURIComponent(AmBase64.encode(AmUtil.relplaceQuots(B)))}return B},getCookieFromEntrenceURL:function(){var C=new Array();var B=window.location.href;if(B){var A=B.indexOf(AmConstant.COOKIE_NAME+"=");C.en=A==-1?escape(B):escape(B.substring(0,A-1));if(A!=-1){C[AmConstant.COOKIE_NAME]=B.substring(A+5,B.length)}}return C},getRequestURL:function(D,L,J){var A=this.getCookieFromEntrenceURL();var I=this.getUserIDAndServerIDAsArray(A[AmConstant.COOKIE_NAME]);var H=I?I[AmConstant.AM_UID_ARRAY_SERVER_ID]:"";var B=AmUtil.getProtocol()+"//"+AmUtil.getDomain(H)+AmUtil.getAppName()+"?proto="+AmUtil.getProtocolType()+"&pid="+amPid+"&ck="+(A[AmConstant.COOKIE_NAME]?A[AmConstant.COOKIE_NAME]:AmCookie.get())+"&us="+(window.amCheckThirdParty?"2":AmJSCookie.getCookieEnabled())+"&en="+A.en+"&rp="+escape(document.referrer);if(window.amGeoLocationData){if(!window.amParams){window.amParams=""}if(window.AmGeoLocationDataHandler.getStatus()=="success"){var M=window.AmGeoLocationDataHandler.getData();var F=(new Date().getTime())-M.timestamp;if(isNaN(F)||F<0){F=0}B+="&lat="+((amForceGeoData&&amForceGeoData.lat)?amForceGeoData.lat:(M.coords.latitude))+"&lon="+((amForceGeoData&&amForceGeoData.lon)?amForceGeoData.lon:(M.coords.longitude))+"&geodist="+((amForceGeoData&&amForceGeoData.accuracy)?amForceGeoData.accuracy:(M.coords.accuracy))+"&geots="+F;window.amParams+="GEOlat="+((amForceGeoData&&amForceGeoData.lat)?amForceGeoData.lat:(M.coords.latitude))+"&GEOlon="+((amForceGeoData&&amForceGeoData.lon)?amForceGeoData.lon:(M.coords.longitude))+"&GEOdist="+((amForceGeoData&&amForceGeoData.accuracy)?amForceGeoData.accuracy:(M.coords.accuracy))}else{var M=window.AmGeoLocationDataHandler.getData();if(M.error&&M.error.code){B+="&geoerr="+M.error.code;window.amParams+="GEOerr="+M.error.code;if(M.error.desc){window.amParams+="&GEOdesc="+M.error.desc}}}}if(D||window.amPPid){B+="&ppid="+(D?D:window.amPPid)}B+="&slot="+(L?L:AmConstant.SLOT_TOP);if(!L){var E=AmUtil.getExactQueryStringParam("inplace");if(E){B+="&inplace="+E}}if(J){B+="&isdhtml=true"}B+=(L?"":"&res=r"+screen.width+"x"+screen.height);B+=(L?"":"&gmt="+new Date().getTimezoneOffset()/60*(-1));B+=this.getTestServerParam();B+=this.getAmDebugParam();if(window.amParams){B+="&jsp="+escape(amParams)}if(window.amRevenue){B+="&rev="+escape(amRevenue)}else{if(window.amOrderId){var K=window.amTotalOrder?("&totalOrder="+window.amTotalOrder):"";var G=window.amProductList?("&productId="+window.amProductList):"";B+="&rev="+escape("orderId="+amOrderId+K+G)}}if(window.amCategory){B+="&cat="+this.getCategoryStr()}if(window.amCart){B+="&cart="+amCart}if(window.amRecomRetarget){B+="&rtrgt="+amRecomRetarget}if(window.amRecomMax){B+="&recmax="+amRecomMax}if(window.amRecomMin){B+="&recmin="+amRecomMin}if(window.amRecomMode){B+="&recmode="+amRecomMode}if(window.amProductId){B+="&pctid="+amProductId}if(window.amUserId){B+="&userid="+amUserId}var C=AmUtil.getQueryStringParam("amuc");if(C){B+="&amuc="+C}B+=this.getUIDParam(A[AmConstant.COOKIE_NAME]);B+="&rd="+AmUtil.getRandom();return B},getClickRequestURL:function(F){var B=AmContentManager.getContent(F);if(!B){return }var C=this.getCookieFromEntrenceURL();var E=this.getUserIDAndServerIDAsArray(C[AmConstant.COOKIE_NAME]);var A=E?E[AmConstant.AM_UID_ARRAY_SERVER_ID]:"";var D=AmUtil.getProtocol()+"//"+AmUtil.getDomain(A)+AmConstant.INT_COUNTER+"?&pid="+amPid;D+=this.getUIDParam(C[AmConstant.COOKIE_NAME]);D+="&vsid="+AmCookie.visitID;D+="&hc="+AmCookie.hitsCounter;D+="&prid="+AmCookie.profileID;D+="&egid="+B.egID;D+="&tid="+B.testID;D+="&ttype="+B.testType;D+="&wid="+B.webletID;D+="&evt=8,w,"+B.webletID;D+=this.getTestServerParam();return D},isInplaceTaggingMode:function(){var A=AmJSCookie.get(AmConstant.INPLACE_TAGGING_MODE_COOKIE_NAME);if(amGetQueryVariable(AmConstant.INPLACE_FORCE_TAGGING_MODE)!=-1){A="true"}return A&&A==="true"},callInplaceTaggingMode:function(){var A=this.getInplaceTaggingModeRequestURL();AmManagerCommon.checkCookieSetTimeoutAndWriteScript(A)},getInplaceTaggingModeRequestURL:function(){var B=AmUtil.getProtocol()+"//"+AmUtil.getDomain()+AmConstant.APP_INPLACE_NAME+"?proto="+AmUtil.getProtocolType()+"&pid="+window.amPid;B+="&ppid="+(window.amPPid?window.amPPid:"0");B+="&slot="+AmConstant.SLOT_TOP;if(window.location.href){B+="&en="+escape(window.location.href)}var A=AmUtil.getExactQueryStringParam("inplace");if(A){B+="&inplace="+A}B+="&rd="+AmUtil.getRandom();return B},exelateResponse:function(){if(AmManager.exelateTimeOutCall){AmManager.serverRequest()}},serverRequest:function(B,E,A){var D="";if(!E&&!B&&this.exelateTimeOutCall){clearTimeout(AmManager.exelateTimeOutCall);AmManager.exelateTimeOutCall="";AmManager.saveExelateContent();D=AmManager.getRequestURL();AmManagerCommon.checkCookieSetTimeoutAndWriteScript(D)}else{D=this.getRequestURL(B,E,A);if(A){var C=document.createElement("script");C.src=D;document.body.appendChild(C)}else{AmManagerCommon.checkCookieSetTimeoutAndWriteScript(D)}}},getProductsRequestURL:function(B){var C=this.getUserIDAndServerIDAsArray();var A=C?C[AmConstant.AM_UID_ARRAY_SERVER_ID]:"";return AmUtil.getProtocol()+"//"+AmUtil.getDomain(A)+AmConstant.INT_PRODUCTS+"?pid="+amPid+((window.amProductId)?("&pctid="+amProductId):"")+this.getProductsDataRequestURL(B)+"&cat="+this.getCategoryStr()+this.getUIDParam()+this.getTimeStampParam()},getImageRequestURL:function(){var B=this.getUserIDAndServerIDAsArray();var A=B?B[AmConstant.AM_UID_ARRAY_SERVER_ID]:"";return AmUtil.getProtocol()+"//"+AmUtil.getDomain(A)+AmConstant.INT_STUB+"?ct="+AmConstant.IMAGE_CONTENT_TYPE+this.getUIDParam()},getProductsDataRequestURL:function(A){var B="";if(A){B="&pctdat="+window.amProductData}else{B="&pimg="+(window.amProductImg?escape(window.amProductImg):"")+"&plink="+(window.amProductLink?escape(window.amProductLink):"")+"&ptitle="+(window.amProductTitle?window.encodeURIComponent(AmBase64.encode(AmUtil.relplaceQuots(window.amProductTitle))):"")+"&pdesc="+(window.amProductDesc?window.encodeURIComponent(AmBase64.encode(AmUtil.relplaceQuots(window.amProductDesc))):"")+"&pdprice="+(window.amProductDisplayPrice?escape(window.amProductDisplayPrice):"")+"&plprice="+(window.amProductListPrice?escape(window.amProductListPrice):"")+"&pstatus="+(window.amProductStatus?window.amProductStatus:"")}return B},serverRequestProductsInternal:function(A){var B=AmManager.getProductsRequestURL(A);if(!AmManager.AM_DISABLE_AMADESA){AmUtil.sendImageRequest(B,null)}},serverRequestProducts:function(){AmManager.serverRequestProductsInternal(false)},serverRequestSecureProducts:function(){if(window.amProductData){AmManager.serverRequestProductsInternal(true)}}};AmManager.init();
