/* IOL COMSCORE engine Version 1.60 */ if(typeof(Libero)=="undefined"){Libero={}}if(typeof(Libero.Stash)=="undefined"){Libero.Stash={}}if(typeof(Prototype)=="undefined"){var Class={create:function(){return function(){this.initialize.apply(this,arguments)}}}}Libero.objectExtend=function(a,c){for(var b in c){if(typeof(c[b])!="undefined"){a[b]=c[b]}}return a};try{Libero.Stash.csDebug=libero_comscore_debug}catch(e){}try{Libero.Stash.csTest=libero_comscore_test}catch(e){}try{Libero.Stash.csCNAutoComplete=libero_comscore_cnautocomplete}catch(e){}try{Libero.Stash.csCheckMultipleCalls=libero_comscore_check_multiple_calls}catch(e){}try{Libero.Stash.csObj=libero_comscore_csobj}catch(e){}try{Libero.Stash.csLabels=libero_comscore_labels}catch(e){}if(/\.(st|pp)\.libero\.it(:\d+)?$/.test(document.location.host)){Libero.Stash.csTest=1;Libero.Stash.csDebug=1}if(/Libero(Tracking|Comscore)Debug=(\d+)/.test(document.cookie)){Libero.Stash.csDebug=parseInt(RegExp.$2)}if(typeof console=="undefined"){Libero.Stash.csDebug=0}if(Libero.Stash.csDebug){console.log("[LT]","Loading tracking engine")}if(typeof Libero.Stash.csImages!="number"){Libero.Stash.csImages=0}Libero.getTrackingLegacy=function(){var args=Libero.objectExtend({csObj:Libero.Stash.csObj,ajax:undefined,url:document.location.href,path:document.location.pathname,cookie:document.cookie,search:document.location.search,hash:document.location.hash,referrer:document.referrer,debug:Libero.Stash.csDebug,test:Libero.Stash.csTest,callDirectly:0,callJS:0,https:document.location.protocol=="https:",log_prefix:"[LT]",check_multiple_calls:Libero.Stash.csCheckMultipleCalls,add_host_to_cn:Libero.Stash.csCNAutoComplete,onLoadHandler:undefined,labels:Libero.Stash.csLabels||{},timeout:2,trackingUrl:undefined,addTimestampToUrl:true,cacheCountername:false,skipCountername:false,cs_ns_site:"libero",cs_c2:"13259779",profile:true,title:document.title,charset:document.characterSet||document.defaultCharset,vportal:0},arguments[0]);if(typeof console=="undefined"){args.debug=0}args.version="1.60";if(args.debug){console.log(args.log_prefix,"getTracking ("+args.version+")",args)}var countername;var callback_name;if(args.skipCountername===false){if(args.cacheCountername&&typeof(Libero.Stash.csName)!="undefined"){countername=Libero.Stash.csName;if(args.debug){console.log(args.log_prefix,"Getting cn from cache: ",countername)}}else{if(typeof(args.csObj)=="undefined"||typeof(args.csObj.cn)!="object"){if(args.debug){console.log(args.log_prefix,"Undefined 'csObj'")}return undefined}countername=args.csObj.defaultCn;callback_name=null;for(var i=0,l=args.csObj.cn.length;i0&&Libero.Stash.csImages>args.check_multiple_calls){if(args.debug){console.log(args.log_prefix,"Tracking skipped, the calls ("+Libero.Stash.csImages+") reached max limit ("+args.check_multiple_calls+")")}}else{if(typeof(args.labels.wa_header)==="undefined"&&/^vportals/.test(args.cs_ns_site)){if(document.getElementById("vh_header_top")){args.labels.wa_header="virgilio"}else{if(document.getElementById("l_header_topbar")){args.labels.wa_header="libero"}}}if(args.vportal){args.referrer=document.referrer?args.referrer:document.referrer}if(args.profile){if(typeof(getFup)==="function"){var fup=getFup();if(typeof(fup)==="object"){if(args.debug){console.log(args.log_prefix,"FUP object ok",fup,IOLOBJ)}args.labels.wa_geo_1_id=fup.gic;args.labels.wa_geo_2_id=fup.gip;args.labels.wa_geo_3_id=fup.gis;args.labels.wa_geo_4_id=fup.gcrl;args.labels.wa_local_1_id=fup.lip;args.labels.wa_local_2_id=fup.lic;args.labels.wa_local_3_id=fup.lir;args.labels.wa_adv_1_id=fup.sse;args.labels.wa_adv_2_id=fup.sfe;args.labels.wa_adv_3_id=fup.spr;if(typeof(fup.ext)==="object"&&/^\d+$/.test(fup.ext.uos)&&/^\d+$/.test(fup.ext.uab)){args.labels.cs_wn="u"+(parseInt(fup.ext.uab)+1800+1999)+"z"+(fup.ext.uos==122?1:fup.ext.uos==133?2:0)}}}else{if(args.debug){console.log(args.log_prefix,"FUP object ko")}if(typeof(iol_profile_data)!="object"||typeof(iol_profile_data.geo)!="object"){if(args.debug){console.log(args.log_prefix,"iol_profile_data ko")}try{iol_profile_data=(new IOL.Profile()).getProfile();if(args.debug){console.log(args.log_prefix,"IOL.Profile ok")}}catch(e){if(args.debug){console.log(args.log_prefix,"IOL.Profile ko")}}}else{if(args.debug){console.log(args.log_prefix,"iol_profile_data ok")}}if(typeof(iol_profile_data)==="object"){if(typeof(iol_profile_data.geo)==="object"){args.labels.wa_geo_1_id=iol_profile_data.geo.istatComune;args.labels.wa_geo_2_id=iol_profile_data.geo.istatProvincia;args.labels.wa_geo_3_id=iol_profile_data.geo.isp;args.labels.wa_geo_4_id=iol_profile_data.geo.codiceRegione}if(typeof(iol_profile_data.local)==="object"){args.labels.wa_local_1_id=iol_profile_data.local.idprovincia;args.labels.wa_local_2_id=iol_profile_data.local.idcity;args.labels.wa_local_3_id=iol_profile_data.local.regione}if(typeof(iol_profile_data.adv)==="object"){args.labels.wa_adv_1_id=iol_profile_data.adv.sesso;args.labels.wa_adv_2_id=iol_profile_data.adv.fasciaEta;args.labels.wa_adv_3_id=iol_profile_data.adv.provincia}}}}args.labels.wa_engine_v=args.version;if(args.skipCountername===false&&typeof(args.csObj.version)!="undefined"){args.labels.wa_data_v=args.csObj.version}if(typeof(args.referrer)!="undefined"&&!/^\s*$/.test(args.referrer)&&!/^https?:\/\//.test(args.referrer)){args.referrer="http://"+args.referrer}if(args.callDirectly){var i=new Image(),esc=typeof(encodeURIComponent)=="function"?encodeURIComponent:escape,label_qs="";if(typeof(args.labels)=="object"){for(var prop in args.labels){if(typeof(args.labels[prop])=="undefined"){continue}label_qs+="&"+prop+"="+esc(args.labels[prop])}}if(typeof(args.onLoadHandler)=="function"){if(args.debug){console.log(args.log_prefix,"Adding onload handler: ",args.onLoadHandler)}var tracking_timeout=window.setTimeout("Libero.Stash.csOnLoad()",args.timeout*1000);Libero.Stash.csOnLoad=function(){try{window.clearTimeout(tracking_timeout)}catch(e){}i.onload=i.onerror=function(){return};args.onLoadHandler()};i.onload=Libero.Stash.csOnLoad;i.onerror=Libero.Stash.csOnLoad}if(typeof(args.trackingUrl)!="undefined"&&typeof(args.trackingUrl)=="string"){i.src=args.trackingUrl+(args.addTimestampToUrl===true?(/\?/.test(args.trackingUrl)?"&":"?")+"_t="+ +(new Date):"")}else{i.src=(args.https?"https://sb":"http://b")+".scorecardresearch.com/b?c1=2&c2="+args.cs_c2+"&name="+esc(countername)+"&ns_site="+(args.test?"test":args.cs_ns_site)+"&c7="+esc(args.url)+"&c8="+esc(args.title)+"&c9="+esc(args.ajax||args.referrer)+"&ns__t="+ +(new Date)+"&ns_c="+esc(args.charset)+label_qs}if(args.debug){console.log(args.log_prefix,"Making direct call to ",i)}}else{if(args.debug){console.log(args.log_prefix,"Making standard call...")}COMSCORE.beacon(Libero.objectExtend({c1:2,c2:args.cs_c2,name:countername,ns_site:args.test?"test":args.cs_ns_site},typeof(args.labels)=="object"?args.labels:{}))}if(callback_name){try{window[callback_name](countername)}catch(e){if(args.debug){console.log(args.log_prefix,e)}}}}}if(args.debug&&args.skipCountername===false){console.log(args.log_prefix,"The winner is: "+countername)}return countername};Libero.getComscore=Libero.getTrackingLegacy;Libero.click=function(){var d,a=0,b={};if(typeof(arguments[0])=="object"&&arguments[0].tagName=="A"){b=arguments[0];if(typeof(b.href)=="string"){if(b.target){d=function(){window.open(b.href,b.target)}}else{d=function(){document.location.href=b.href}}a=1}}else{if(typeof(arguments[0])=="object"&&arguments[0].tagName=="FORM"){b=arguments[0];d=function(){b.submit()};a=1}else{a=0}}var c=Libero.objectExtend({callDirectly:1,cacheCountername:1,profile:false,onLoadHandler:d},arguments[a]);c.labels=Libero.objectExtend(c.labels||{},{ns_type:"hidden",lib_name:Libero.Stash.csName,lib_ev_type:"click",lib_dest:b.href});return Libero.getTrackingLegacy(c)};Libero.CGI=function(a){var d;if(typeof(a)=="undefined"||typeof(a)!="string"){return{}}d=a.split(/\?/)[1];if(d){this.search=d;var c=this.search.split(/\&+/);for(var b=0;b0;n--){o+=m.indexOf(j.charAt(n-1))*Math.pow(16,k);k++}return String.fromCharCode(o)})}this[f[0]]=f[1]}}else{return{}}};Libero.Stash.q=new Libero.CGI(document.location.href);Libero.Stash.csCall=0;for(var type=["url","cookie","path","ajax","hash","directly","referrer"],i=0;i0){Libero.Stash.csName=Libero.getTrackingLegacy({url:Libero.Stash.q.cs_url,path:Libero.Stash.q.cs_path,cookie:Libero.Stash.q.cs_cookie,ajax:Libero.Stash.q.cs_ajax,hash:Libero.Stash.q.cs_hash,callDirectly:1,debug:parseInt(Libero.Stash.csDebug||Libero.Stash.q.cs_debug),test:parseInt(Libero.Stash.csTest||Libero.Stash.q.cs_test),https:parseInt(Libero.Stash.q.cs_https)||undefined,referrer:Libero.Stash.q.cs_referrer,title:Libero.Stash.q.cs_title,vportal:parseInt(Libero.Stash.q.cs_vp)||undefined,charset:Libero.Stash.q.cs_charset})}else{Libero.Stash.csName=Libero.getTrackingLegacy({callJS:1,debug:parseInt(Libero.Stash.csDebug||Libero.Stash.q.cs_debug),test:parseInt(Libero.Stash.csTest||Libero.Stash.q.cs_test),referrer:Libero.Stash.q.cs_referrer,vportal:parseInt(Libero.Stash.q.cs_vp)||undefined})};