function VastImpressions(a){this.id="w"+Math.floor(Math.random()*100001);if((typeof window.vimp)!="object"){window.vimp={}}window.vimp[this.id]=this;this.impressURL=window.location.protocol=="http:"?"http://a.vast.com/impressions":"https://sa.vast.com/impressions";this.params=a;this.impress()}VastImpressions.prototype.impress=function(){this.params.domain=this.extractDomainName();this.params.aref=encodeURIComponent(document.referrer);this.params.aurl=encodeURIComponent(window.location.href.replace(/\#.+$/,""));this.params.uagent=encodeURIComponent(navigator.userAgent);this.params.res=screen.width+"x"+screen.height;this.params.activex=this.getAx();var b=this.getCookie("V_AB");if(b){this.params.ab=encodeURIComponent(b)}if(typeof v_clientStartTime == 'object'){var v_clientEndTime = new Date();var loadTime = v_clientEndTime.getTime() - v_clientStartTime.getTime();this.params.load_time = loadTime.toString();v_clientStartTime = undefined;}var a=this.getCookie("V_UID");if(!a){a=this.createUID()}this.logImp({uid:a})};VastImpressions.prototype.getAx=function(){if(navigator.appVersion.match(/MSIE/i)){try{new ActiveXObject("Msxml2.XMLHTTP")}catch(a){try{new ActiveXObject("Microsoft.XMLHTTP")}catch(a){return"disabled"}}return"enabled"}else{return"not_supported"}};VastImpressions.prototype.createUID=function(){var d="abcdefghijklmnopqrstuvwxyz0123456789";var f=32;var b="";for(var c=0;c<f;c++){var a=Math.floor(Math.random()*d.length);b+=d.substring(a,a+1)}return b};VastImpressions.prototype.extractDomainName=function(){var b=new RegExp("http[s]{0,1}://([a-zA-Z0-9.-]+)(/{0,1}.*)","i");var a=b.exec(window.location.href);if(a&&a[1]){return encodeURIComponent(a[1])}return false};VastImpressions.prototype.logImp=function(d){if(d&&d.uid){this.params.uid=encodeURIComponent(d.uid);this.setCookie("V_UID",d.uid,365,"/");var b=this.impressURL;var a=true;for(var c in this.params){if(a){a=false;b+="?"}else{b+="&"}b+=c+"="+this.params[c]}this.doRequest(b)}};VastImpressions.prototype.doRequest=function(a){this.insertScript({src:a,type:"text/javascript"})};VastImpressions.prototype.insertScript=function(f,c){if(f){if(!c){var d=document.createElement("script")}else{var d=document.createElement(c)}for(var b in f){if(b=="text"){d.innerHTML=f[b]}else{d.setAttribute(b,f[b])}}var a=document.getElementsByTagName("head")[0];a.appendChild(d)}};VastImpressions.prototype.setCookie=function(c,f,a,j,d,h){var b=new Date();b.setTime(b.getTime());if(a){a=a*1000*60*60*24}var g=new Date(b.getTime()+(a));document.cookie=c+"="+escape(f)+((a)?";expires="+g.toGMTString():"")+((j)?";path="+j:"")+((d)?";domain="+d:"")+((h)?";secure":"")};VastImpressions.prototype.getCookie=function(a){var g=document.cookie.split(";");var b="";var d="";var f="";var c=false;for(i=0;i<g.length;i++){b=g[i].split("=");d=b[0].replace(/^\s+|\s+$/g,"");if(d==a){c=true;if(b.length>1){f=unescape(b[1].replace(/^\s+|\s+$/g,""))}return f;break}b=null;d=""}if(!c){return null}};try{runVastImpression()}catch(e){};
