var VOXUS_DEBUG=false;try{var usubida_domain='//api-dsp.voxus.tv';var usubidaPages=["/pedido-finalizado"];var clientDomain='www.despachantedok.com.br';var clientDomainWl=JSON.parse('["www.despachantedok.com.br","checkout.despachantedok.com.br"]');var subusubidaPages=["checkout","cart","pedido"];var igpgs=[];var usubidaFBPixels=[];var voxus_key='voxusmediamanager';var voxus_keypip='appclustervoxuskey';var client_id='1148';var sgotasd=[["/",786],["/endereco",786],["/pagamento",786],["/licenciamento-online",786],["/debitos",786],["/checkout",786],["//",786],["/transferencia",786],["/informacoes",786],["/ipva-atrasado",786],["/usuario",786],["/painel",786],["/resumo",786],["/pagamento-cartao-preenchimento",786],["/quantidade-cartoes",786],["/forma-pagamento",786],["/cadastro-entrega",786],["/orcamento",786],["/redefinir-senha",786],["/despachante",786],["/detran-rj",786],["/como-consultar-debitos-de-veiculo",786],["/divida-ativa",786],["/tab=inicio",786],["/tab=veiculos",786],["shipping",161],["payment",50],["cart",128],["portinari",58],["aquecedor",74],["review",113],["prateleiras",45],["sasazaki",26],["conexoes",118],["popular",88],["delta",114],["bronzearte",52],["tinta",121],["tigre",41],["caixa",43],["massa",71],["piso-45x45-a-vivence-140016-pei4-art-cx204-incopisos",84],["cozimax",91],["banqueta",75],["pisos",136],["busca",101],["banheiro",76],["iluminacao",28]];var logglyloadvoxus=false;var lastDataLoggly=null;var thisip=null;var getip=null;var getIP=function(){};var axel=Math.random()+"";var a=axel*10000000000000;var sgarq=function(){};var intervalDocumentOnloadVoxusDsp=null;var sgarq=function(){} var voxusAnalyticsValidation=function(){} var sgarqRun=true;var checkEnterprise=function(){};var dataExcludeValidated=false;var intervalDataExcludeValidated;var interPixel=false;var interConversion=false;var igvxtst=false;var igvxgtst=false;var kopid=false;var kopiduh=false;var adinter=false;var sent_usubida=false;var sentloggly=false;var alihuadsa=false;var alihuadsanw=false;var fromOther=false;var pipcluster=false;var converted=false;var converted_gl=0;var retroative=0;var cookie_id=null;var ismobile=false;var creativekaoq=false;var ___vx__runCVL=(0==1?true:false);var sgotasdkaoq=false;var kopidCooked=false;var totalSes=0;var isicgt=false;var enterpriseId=0;var urlsToBloq=[];var redir=0;var imp=1;var attmob=1;var alcm=null;var alcc=null;var isChrome=false;var kiphouYiasO=[];var alvx2=null;var alvx1=null;var alvx3=null;var lswf=false;var dc=false;var tfAdvId=0;var tfCpgId=0;var tfDsName='';var tfDsTid='';var dsName='';var tID='';var advCtmzs=JSON.parse("{\"ds_hit\":true,\"ga_hit\":true,\"ga4_reset_session\":true,\"custom_pixels\":true,\"user_behavior\":true,\"custom_tracking\":true,\"new_user_reset\":true,\"cd-attr\":true,\"other_v2\":true}");var adsWithCustomData=JSON.parse("[]");var advWithCustomUtm=JSON.parse("[]");var advCustomPixels=JSON.parse("{\"session_time\":[{\"pixel_id\":\"38626857\",\"minimum_time\":120}]}");var wppTriggered=false;var appointmentTriggered=false;var trackedElements={};var observerController={observers:{},observedDomains:{},observedRequests:{},};var tagVersion='20250924_120908';var tagSemanticVersion='1.0.239';var cachedVerifyRequest={'queue':{},'resolved':{}};var indexNckVersion='1.0.6';var fromOtherv2=false;var gaNotSentReason=null;var algs=null;var analyticsAttributionHitsSentOnPage={ga:false,ds:false,tfDs:false};const analyticsServersReceivedHitsOnPage=Object.fromEntries(getMeasurementIds().map(id=>[id,false]));var noNewUserResetReason=null;if(enterpriseId==0||client_id==98){var VOXUS_RTDT_DATA=encodeURIComponent("client=DOK Despachante&website_id=1148&obj=238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47&type=pageview");}else{var VOXUS_RTDT_DATA=encodeURIComponent("client=DOK Despachante&website_id=0&obj=238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47238b5637f41f33387ecb9ff9fb2f3e47&type=pageview");} class VxLogger{debug(...args){if(VOXUS_DEBUG){console.debug(...args);}} trace(...args){if(VOXUS_DEBUG){console.trace(...args);}}} const vxLogger=new VxLogger();class VxAsyncWrapper{static setTimeout(callback,delay,...args){return setTimeout(()=>{try{callback?.(...args);}catch(error){vxLogger.debug("Error in `setTimeout` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}},delay);} static setInterval(callback,delay,...args){return setInterval(()=>{try{callback?.(...args);}catch(error){vxLogger.debug("Error in `setInterval` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}},delay);}} function fallBackLocalstorage(){if(window.localStorage){return;} window.localStorage={getItem:()=>{},setItem:()=>{},};} fallBackLocalstorage();function getDataLayerItemWith(eventCheckCallback,dataLayerName='dataLayer'){for(const dataLayerItem of window[dataLayerName]){if(eventCheckCallback(dataLayerItem)){return dataLayerItem;}} return null;} function isVoxusLastPaidMedia(){const timestampCookie=CookiesVx.get('voxus_last_impression_timestamp_'+client_id);if(!timestampCookie){return false;} const now=Math.floor(Date.now()/1000);const impressionTimestamp=parseInt(timestampCookie,10);const twentyFourHoursInSeconds=24*3600;if(now-impressionTimestamp>twentyFourHoursInSeconds){return false;} if(!hasActivePaidMedia()){return true;} const activePaidMedia=getActivePaidMedia();if(!activePaidMedia){return true;} const isVoxusLastPaidMedia=activePaidMedia.time{function checkDataLayer(){try{if(window[dataLayerName].length===originalSize){VxAsyncWrapper.setTimeout(checkDataLayer,delay);return;} const itemFound=window[dataLayerName].find(eventCheckCallback);if(itemFound){resolve(itemFound);return;} originalSize=window[dataLayerName].length;VxAsyncWrapper.setTimeout(checkDataLayer,delay);}catch(error){vxLogger.debug("Error in `listenDataLayerChangesUntil` for advertiser: ",client_id,error);vxLogger.trace(error.stack);reject(error);}} checkDataLayer();});} function setisicgt(i){isicgt=i;} var fs=window.RequestFileSystem||window.webkitRequestFileSystem;if(!fs){}else{fs(window.TEMPORARY,100,setisicgt.bind(setisicgt,false),setisicgt.bind(setisicgt,true));} if(navigator!=null){if(navigator.userAgent!=null){if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){ismobile=true;}}} var __domain__=(function(){var i=0,domain=document.domain,p=domain.split('.'),s='_gd'+(new Date()).getTime();while(i<(p.length-1)&&document.cookie.indexOf(s+'='+s)==-1){domain=p.slice(-1-(++i)).join('.');document.cookie=s+"="+s+";domain="+domain+";";} document.cookie=s+"=;expires=Thu, 01 Jan 1970 00:00:01 GMT;domain="+domain+";";return domain;})();function hasCustomization(customizationType){return typeof(advCtmzs[customizationType])!='undefined'&&advCtmzs[customizationType]===true;} function getLastAdSeen(){if(typeof(CookiesVx.get(voxus_key+'_kopid_uh_pip'))=='undefined') return'';let adSeenPieces=CookiesVx.get(voxus_key+'_kopid_uh_pip').split('-');return adSeenPieces.length===0?'':adSeenPieces[0];} function addMinutesToDate(date,minutes){return new Date(date.getTime()+minutes*60000);} function addHoursToDate(date,hours){const newDate=new Date(date.getTime());newDate.setHours(newDate.getHours()+hours);return newDate;} function addDaysToDate(date,days){const newDate=new Date(date.getTime());newDate.setDate(newDate.getDate()+days);return newDate;} function minutesFromTimestamp(earlierTimestamp){return Math.floor((Math.floor(Date.now()/1000)-earlierTimestamp)/60);} function getHardCodedMeasurementIds(){const manualClientTrackingMap=new Map([['2726',['G-JPJPRSDB9K']],['1852',['G-ZM0BG28WWR']],['2859',['G-ZQG965CFCJ']],['2783',['G-NM6XDMNB2W']],['1985',['G-SZ828V6WSK']],['2701',['DC-11379620','G-WCFX1FQ26K','AW-804145559']],['1948',['G-78EPY23H13','G-7HNMFXJ8J5','G-B0521B3853','G-HMCQCM5KQ1','G-NY5NGVZ1KQ','G-S02H216ES2']],['1879',['G-PYGGC1W2VQ']],['2900',['G-4CZX459Q1Q','G-G5LR3WEXK4']],['1598',['corebiz_google_app','G-TCKVZX1BJB','G-HN1RYJHPJ7']],]);return manualClientTrackingMap.get(client_id)||[];} function getMeasurementIdsFromGtm(){if(typeof google_tag_manager==='undefined'){return[];} const allOptions=Object.keys(google_tag_manager);if(allOptions.length===0){return[];} return allOptions.filter(option=>{return option.substring(0,2)==='G-';});} function getMeasurementIdsFromGtmDestination(){if(typeof google_tag_data==='undefined'||!google_tag_data?.tidr?.destination){return[];} return Object.keys(google_tag_data.tidr.destination).filter((item)=>item.startsWith('G-'));} function getMeasurementIds(){if(!hasCustomization('ga_hit')){return[];} const mIdsSet=new Set([...getHardCodedMeasurementIds(),...getMeasurementIdsFromGtm(),...getMeasurementIdsFromGtmDestination()]);return[...mIdsSet];} function getFixedMeasurementId(){let fixedMeasurementId=CookiesVx.get('measurement_id');if(typeof fixedMeasurementId=='undefined'||!isMeasurementIdValid(fixedMeasurementId)){fixedMeasurementId=getMeasurementIds()?.[0];if(!fixedMeasurementId) return null;} CookiesVx.set('measurement_id',fixedMeasurementId) return fixedMeasurementId;} function isMeasurementIdValid(measurementId){const validMeasurementIds=getMeasurementIds();if(!validMeasurementIds||validMeasurementIds?.length===0){return false;} return validMeasurementIds.includes(measurementId);} function parseGaMainCookie(){const key='_'+'ga';const fullCookie=CookiesVx.get(key);if(!fullCookie){return null;} const splited=fullCookie.split('.');const userId=`${splited[2]}.${splited[3]}`;return{key,value:fullCookie,timestamp:splited[3],userId,};} function getGaSessionCookieData(measurementId){if(!measurementId){return null;} const key='_'+'ga_'+measurementId.slice(2);const fullCookie=CookiesVx.get(key);if(!fullCookie){return null;} const mainCookie=parseGaMainCookie();if(!mainCookie){return null;} const isSessionCookieNewVersion=isGS2Implementation(fullCookie);return{key,value:fullCookie,userId:mainCookie.userId,userTimestamp:mainCookie.timestamp,sessionId:getGaCookieSessionId(isSessionCookieNewVersion,fullCookie),sessionLastInteraction:getSessionLastInteraction(isSessionCookieNewVersion,fullCookie),sessionCount:getSessionCount(isSessionCookieNewVersion,fullCookie),newUser:getSessionNewUser(isNewGaSessionCookie,fullCookie)};} function isGS2Implementation(fullCookie){return fullCookie.startsWith('GS2');} function getGaCookieSessionId(isNewVersion,fullCookie){if(isNewVersion){const splited=fullCookie.split('$');const sessionIdPart=splited.find(p=>p.includes('.s'));return sessionIdPart?sessionIdPart.split('.s')[1]:null} return fullCookie.split('.')[2];} function getSessionLastInteraction(isNewVersion,fullCookie){if(isNewVersion){const splited=fullCookie.split('$');return splited.find(p=>p.startsWith('t'))?.substring(1)||null} return fullCookie.split('.')[5];} function getSessionCount(isNewVersion,fullCookie){if(isNewVersion){const splited=fullCookie.split('$');const sessionCountPart=splited.find(p=>p.startsWith('o'));return sessionCountPart?sessionCountPart.substring(1):null;} return fullCookie.split('.')[3];} function getSessionNewUser(isNewVersion,fullCookie){if(isNewVersion){const splited=fullCookie.split('$');const newUserPart=splited.find(p=>p.startsWith('o'));return newUserPart?newUserPart.substring(1)==='1':false;} return fullCookie.split('.')[3]==='1';} function expireCookie(cookieKey){CookiesVx.set(cookieKey,'',{expires:new Date(0).toGMTString(),});} function isNewGaSessionCookie(measurementId){const gaCookieData=getGaSessionCookieData(measurementId) if(!gaCookieData) return false;return gaCookieData.sessionCount==='1'&&gaCookieData.newUser;} function isNewUser(){const mainCookie=parseGaMainCookie();if(!mainCookie){return false;} const isNewUserByTime=minutesFromTimestamp(Number(mainCookie.timestamp))<=1;const measurementIds=getMeasurementIds();if(!measurementIds||measurementIds?.length===0){return false;} const isNewUserByAnySession=measurementIds.some((measurementId)=>isNewGaSessionCookie(measurementId));return isNewUserByTime||isNewUserByAnySession;} function resetGa4User(measurementId){const gaCookiedata=getGaSessionCookieData(measurementId);if(isNewUser()){expireCookie(gaCookiedata.key);}} function modifyGa4SessionCookie({measurementId,newTimestamp}){const gaCookiedata=getGaSessionCookieData(measurementId);if(!gaCookiedata){return;} if(!gaCookiedata.sessionLastInteraction){return;} const newGaSessionCookie=gaCookiedata.value.replace(gaCookiedata.sessionLastInteraction,newTimestamp);CookiesVx.set(gaCookiedata.key,newGaSessionCookie,{domain:'.'+__domain__,expires:addDaysToDate(new Date,729).toGMTString()});} function resetGa4Session(measurementIds){if(!measurementIds||!measurementIds.length){return;} const newTimestamp=Math.floor(addHoursToDate(new Date,-6).getTime()/1000);const voxusGaSessionResetedCookieKey=voxus_key+"_session_reseted";const voxusGaSessionResetQtCookieKey=voxus_key+'_session_reset_qt';const resetCap=hasCustomization('measurement_protocol_fix')?3:1;const isSessionReseted=Boolean(CookiesVx.get(voxusGaSessionResetedCookieKey));const rawValue=CookiesVx.get(voxusGaSessionResetQtCookieKey);const amountOfResets=isNaN(Number(rawValue))?0:Number(rawValue);if(isSessionReseted&&amountOfResets>=resetCap){return;} for(const measurementId of measurementIds){modifyGa4SessionCookie({measurementId,newTimestamp,});} CookiesVx.set(voxusGaSessionResetedCookieKey,true,{domain:'.'+__domain__,expires:addMinutesToDate(new Date,30).toGMTString()});CookiesVx.set(voxusGaSessionResetQtCookieKey,amountOfResets+1,{domain:'.'+__domain__,expires:addMinutesToDate(new Date,30).toGMTString()});} async function sendToLoggly(data){try{return await fetch("https://logs-01.loggly.com/inputs/27cf9a30-eb89-41a7-ba82-3280d33fb2cf/tag/https/",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8",},body:JSON.stringify(data),});}catch(error){vxLogger.debug("Error in `sendToLoggly` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}} function getUserSessionData(measurementId=null){if(!measurementId){measurementId=getMeasurementIds()[0];} let vxSessionId=CookiesVx.get('vx_session_id');let gaSessionData=getGaSessionCookieData(measurementId);if(!gaSessionData) return null;let gaCurrentSession=gaSessionData.userId;if(typeof vxSessionId=='undefined'||vxSessionId!=gaCurrentSession){refreshVoxusSession(gaSessionData);} let currentEpochTime=parseInt(Date.now()/1000);let sessionTime=currentEpochTime-CookiesVx.get('vx_session_start');let vxSessionPagesQt=parseInt(CookiesVx.get('vx_session_pages_qt'));vxSessionPagesQt=vxSessionPagesQt+1;CookiesVx.set('vx_session_pages_qt',parseInt(vxSessionPagesQt));return{'vx_session_id':vxSessionId,'session_time':sessionTime,'vx_session_pages_qt':vxSessionPagesQt}} function refreshVoxusSession(gaSessionData){let user_id=gaSessionData.userId;let session_id=gaSessionData.sessionId;CookiesVx.set('vx_session_id',user_id);CookiesVx.set('vx_session_start',session_id);CookiesVx.set('vx_session_pages_qt',0);} function addPixel(url,isReferrerPolicy=false){const px=document.createElement('img');px.src=url;px.width=1;px.height=1;px.style='display:none;visibility:hidden';if(isReferrerPolicy){px.referrerPolicy="unsafe-url";} const body=document.getElementsByTagName('body')[0];if(body){body.appendChild(px);}else{document.addEventListener('DOMContentLoaded',()=>{document.body.appendChild(px);});}} function addXandrPixel(pixelId){const domain=window.location.protocol.indexOf('https:')===-1?'http://ib.adnxs.com/seg?add=':'https://secure.adnxs.com/seg?add=';addPixel(domain+pixelId+'&t=2');} function addMediaMathPixel(advertiser_id){const mediaMathAdvertiserTags={'2321':'https://pixel.mathtag.com/event/js?mt_id=1655596&mt_adid=430561&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','1421':'https://pixel.mathtag.com/event/js?mt_id=1655610&mt_adid=430575&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','2653':'https://pixel.mathtag.com/event/js?mt_id=1657731&mt_adid=431376&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3='};addPixel(mediaMathAdvertiserTags[advertiser_id]);} function addStackAdaptPixelId(pixelId){const stackAdaptBasePixelUrl='https://tags.srv.stackadapt.com/rt?sid=';addPixel(stackAdaptBasePixelUrl+pixelId);} function addStackAdaptPixelIdIfOnSegmentPage({pixelId,segmentName}){if(location.href.includes(segmentName)){addStackAdaptPixelId(pixelId);}} function addMetaPixel(pixelId){addPixel('https://www.facebook.com/tr?id='+pixelId+'&ev=PageView&noscript=1');} function updateSessionTime(sessionTime){let vxSessionId=CookiesVx.get('vx_session_id');if(typeof vxSessionId=='undefined') return;let sessions=typeof CookiesVx.get('vx_user_sessions')!=="undefined"?JSON.parse(CookiesVx.get('vx_user_sessions')):{};const currentTime=Math.floor(Date.now()/1000);sessions[vxSessionId]={sessionTime:sessionTime,timestamp:currentTime};removeExpiredFromUserSessionTime(sessions)} function removeExpiredFromUserSessionTime(sessions){const days=4;const SESSION_TTL=days*24*60*60;const currentTime=Math.floor(Date.now()/1000);Object.keys(sessions).forEach(id=>{if(currentTime-sessions[id].timestamp>=SESSION_TTL){delete sessions[id];}});CookiesVx.set('vx_user_sessions',JSON.stringify(sessions));} function getTotalSessionTime(){let sessions=typeof CookiesVx.get('vx_user_sessions')!=="undefined"?JSON.parse(CookiesVx.get('vx_user_sessions')):{};removeExpiredFromUserSessionTime(sessions) return Object.values(sessions).reduce((sum,session)=>{return sum+(session.sessionTime||0);},0);} function addExcludePixel(){if(client_id=='2581'){addXandrPixel('37611661');}} function addForceIncludePixel(pixelId){addXandrPixel(pixelId);} function manageUserSession(){addExcludePixel();const totalSessionTime=getTotalSessionTime();const mediaMathPixels={'1218':'https://pixel.mathtag.com/event/js?mt_id=1657744&mt_adid=430709&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','2776':'https://pixel.mathtag.com/event/js?mt_id=1657745&mt_adid=430892&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','1774':'https://pixel.mathtag.com/event/js?mt_id=1657746&mt_adid=431230&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','2673':'https://pixel.mathtag.com/event/js?mt_id=1657747&mt_adid=431009&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3=','2249':'https://pixel.mathtag.com/event/js?mt_id=1657748&mt_adid=430883&mt_exem=&mt_excl=&v1=&v2=&v3=&s1=&s2=&s3='};if(mediaMathPixels.hasOwnProperty(client_id)&&totalSessionTime>=120){let requestUrl=mediaMathPixels[client_id];let px=document.createElement('img');px.src=requestUrl;px.async=true;px.width=1;px.height=1;px.frameborder=0;px.style='display:none;visibility:hidden';px.marginheight=0;px.marginwidth=0;px.frameBorder=0;px.scrolling="No";px.hspace=0;px.vspace=0;let bd=document.getElementsByTagName('body')[0].lastChild;bd.parentNode.insertBefore(px,bd);} if(typeof advCustomPixels==='undefined'||!advCustomPixels.hasOwnProperty('session_time')||advCustomPixels.length===0){return;} advCustomPixels['session_time'].forEach(function(sessionTimeItem){if(totalSessionTime>=sessionTimeItem['minimum_time']){addForceIncludePixel(sessionTimeItem['pixel_id']);}});} function manageUserCart(){const advertisersWithCustomCartPixel={'2321':'37800557','1454':'37800555','1416':'37913220'};if(client_id in advertisersWithCustomCartPixel&&hasItemsInDataLayerCart()){addXandrPixel(advertisersWithCustomCartPixel[client_id])}} function manageUser(retries=5,time=1000) {manageUserCart();let gaUserSessionData=getUserSessionData();if(gaUserSessionData){updateSessionTime(gaUserSessionData.session_time);manageUserSession();}else if(retries>0){VxAsyncWrapper.setTimeout(()=>{manageUser(retries-1,time);},time);}} function checkCartItems(dataLayerItem){if(dataLayerItem){if(checkEcommerceItems(dataLayerItem)){return true;} if(checkAddToCartItems(dataLayerItem)){return true;} if(checkSubscriptionEvent(dataLayerItem)){return true;}} return false;} function checkEcommerceItems(dataLayerItem){const validEvents=['add_to_cart','view_cart','begin_checkout'];if(dataLayerItem.ecommerce){if(validEvents.includes(dataLayerItem.event)){const cartItems=dataLayerItem.ecommerce.items;if(cartItems&&cartItems.length>0){return true;}}} return false} function checkAddToCartItems(dataLayerItem){const validEvents=['cart'];if(dataLayerItem.cartProducts){if(validEvents.includes(dataLayerItem.event)){const cartItems=dataLayerItem.cartProducts;if(cartItems&&cartItems.length>0){return true;}}} return false} function checkSubscriptionEvent(dataLayerItem) {const validEventLabels=['formulario:inscricao:inscricao'];if(dataLayerItem.event==='event'&&dataLayerItem.eventLabel){return(validEventLabels.includes(dataLayerItem.eventLabel))} return false;} function hasItemsInDataLayerCart(){return getDataLayerItemWith(checkCartItems)!==null;} function findDataLayer(gtagId){if(!gtagId){return null;} const gtagScripts=document.querySelectorAll('script[src^="https://www.googletagmanager.com/gtag/js"]');for(const tag of gtagScripts){if(!tag.src){continue;} const tagSrc=new URL(tag.src);if(!tagSrc.search.includes(gtagId)){continue;} const dataLayer=tagSrc.searchParams.get('l');if(dataLayer){return dataLayer;}} return null;} function isPageNotRestricted(){if(client_id!=2276||CookiesVx.get(voxus_key+"custom_is_allowed")){return true;} const allowedUrls=['https://www.smiles.com.br/mfe/emissao-passagem','https://www.smiles.com.br/passagens','https://www.smiles.com.br/home',];const currentUrl=window.location.href;const isAllowed=allowedUrls.some(url=>currentUrl.startsWith(url));if(isAllowed){const oneDay=60*60*24 CookiesVx.set(voxus_key+"custom_is_allowed",true,{domain:'.'+__domain__,expires:oneDay});} return isAllowed;} function getCustomUtmFromAssociatedAdvertisers(associatedAdvData,originalSource,originalCampaign,originalMedium){let response={source:originalSource,campaign:originalCampaign,medium:originalMedium};if(typeof associatedAdvData=='undefined'){return response;} Object.values(associatedAdvData).forEach(({kaoq,source,campaign,medium})=>{if(kaoq===true){if(typeof source!='undefined'){response.source=source;} if(typeof campaign!='undefined'){response.campaign=campaign;} if(typeof medium!='undefined'){response.medium=medium;}}});return response;} function getAdvertiserCustomGlobalUtm(advertiser_id,alcs,alcn,alcm){let response={source:alcs,campaign:alcn,medium:alcm,content:'',term:''};if(Object.keys(advWithCustomUtm).length>0){response.source=advWithCustomUtm['utm_source'];response.campaign=advWithCustomUtm['utm_campaign'];response.medium=advWithCustomUtm['utm_medium'];response.content=advWithCustomUtm['utm_content'];response.term=advWithCustomUtm['utm_term'];} return response;} function getDefaultVxSourceParameters(){return[alcs,'voxus'];} function getUtmParametersToSend(alcs,alcm,alcn){let customUtm=getAdvertiserCustomGlobalUtm(client_id,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;if(typeof associatedAdvData!=='undefined'&&associatedAdvData!==null){customUtm=getCustomUtmFromAssociatedAdvertisers(associatedAdvData,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;} const aditionalCustomParameters={};const customParams=advWithCustomUtm['custom_params'];if(customParams&&Object.keys(customParams).length>0){for(const[key,value]of Object.entries(customParams)){aditionalCustomParameters[key]=value;}} const lastAdSeen=getLastAdSeen();if(Object.keys(adsWithCustomData).length===0||lastAdSeen===''||typeof(adsWithCustomData[lastAdSeen])=='undefined'){return{'source':alcs,'medium':alcm,'name':alcn,'content':customUtm.content,'term':customUtm.term,...aditionalCustomParameters};}else{return{'source':adsWithCustomData[lastAdSeen].source!=''?adsWithCustomData[lastAdSeen].source:alcs,'medium':adsWithCustomData[lastAdSeen].medium!=''?adsWithCustomData[lastAdSeen].medium:alcm,'name':adsWithCustomData[lastAdSeen].name!=''?adsWithCustomData[lastAdSeen].name:alcn,'content':adsWithCustomData[lastAdSeen].content,'term':adsWithCustomData[lastAdSeen].term!=''?adsWithCustomData[lastAdSeen].term:'',...aditionalCustomParameters}}} function gtagFunctionFactory(){const tagIds=getMeasurementIds()||[];const dataLayers=["dataLayer"];for(const tagId of tagIds){const dataLayerName=findDataLayer(tagId);if(dataLayerName){dataLayers.push(dataLayerName);}} const uniqueDataLayers=[...new Set(dataLayers)];for(const dataLayerName of uniqueDataLayers){window[dataLayerName]=window[dataLayerName]||[];} return function(){for(const dataLayerName of uniqueDataLayers){window[dataLayerName].push(arguments);}};} function getPageIdentifier(){let pageIdentifier=parseInt(CookiesVx.get('vx_identifier'));if(isNaN(pageIdentifier)){pageIdentifier=1;} return pageIdentifier;} function getAndIncrementPageIdentifier(){const updatedPageIdentifier=getPageIdentifier()+1;CookiesVx.set('vx_identifier',updatedPageIdentifier,{expires:addDaysToDate(new Date,30).toGMTString()});return updatedPageIdentifier;} function observeRequests(domain,callback){if(typeof PerformanceObserver==='undefined'||typeof observerController!=='object'){return null;} if(observerController.observers[domain]){return observerController.observers[domain];} observerController.observedDomains[domain]=false;observerController.observedRequests[domain]=[];observerController.observers[domain]={getRequests:()=>[...observerController.observedRequests[domain]],stop:()=>{let attempts=0;const maxAttempts=10;const interval=setInterval(()=>{if(observerController.observers[domain]?.observerInstance){observerController.observers[domain].observerInstance.disconnect();delete observerController.observers[domain];clearInterval(interval);}else{attempts++;if(attempts>=maxAttempts){clearInterval(interval);}}},100);},observerInstance:null};performance.getEntriesByType("resource").forEach((entry)=>{if((entry.initiatorType==="xmlhttprequest"||entry.initiatorType==="fetch")&&entry.name.includes(domain)){processObservedRequest(entry.name,domain,callback);}});const observer=new PerformanceObserver((list)=>{list.getEntries().forEach((entry)=>{if(entry.initiatorType==="xmlhttprequest"||entry.initiatorType==="fetch"){processObservedRequest(entry.name,domain,callback);}});});observer.observe({entryTypes:["resource"]});observerController.observers[domain].observerInstance=observer;return observerController.observers[domain];} function processObservedRequest(urlString,domain,callback){if(typeof observerController==='undefined'){return;} try{if(urlString.includes(domain)){observerController.observedRequests[domain].push(urlString);observerController.observedDomains[domain]=true;if(typeof callback==="function"){callback(urlString,observerController.observers[domain]);}}}catch(error){vxLogger.debug("Error in ``processObservedRequest` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}} function generateRandomTfd(){return Math.floor(1000+Math.random()*9000);} function generateNewCid(){const timestamp=Math.floor(Date.now()/1000);const randomPart=Math.floor(100000000+Math.random()*900000000);return randomPart+'.'+timestamp;} function generateSid(){return Math.floor(Date.now()/1000);} function getGAUserAgent(){const userAgent=navigator.userAgent;const uaData=navigator.userAgentData;const chromeVersionMatch=userAgent.match(/Chrome\/(\d+\.\d+\.\d+\.\d+)/);const chromeFullVersion=chromeVersionMatch?chromeVersionMatch[1]:'unknown';return uaData.brands.map(brand=>{if(brand.brand==='Google Chrome'){return`${brand.brand};${chromeFullVersion}`;}else if(brand.brand==='Not A;Brand'){return`Not%3BA%3DBrand;${brand.version}.0.0.0`;}else{return`${brand.brand};${brand.version}.0.6613.138`;}}).join('|')} function updateClientGaCookie(newClientId){const gaString='_'+'g'+'a';const originalClientId=CookiesVx.get(gaString);if(typeof originalClientId==='undefined'){return;} const newGaCookie=originalClientId.split('.').slice(0,2).concat(newClientId).join('.');CookiesVx.set(gaString,newGaCookie);} function updateCookieSessionId(sessionId,measurementId){if(!measurementId){return;} const originalSessionCookieId=getGaSessionCookieData(measurementId)?.value;if(!originalSessionCookieId){return;} const gaString='_'+'g'+'a';const gaCookieName=measurementId.replace('G-',gaString+'_');let newSessionCookieId;if(isGS2Implementation(originalSessionCookieId)){const parts=originalSessionCookieId.split('$');const sessionNumber=1;const sessionEngaged=0;const joinTimer=0;const[prefix]=parts[0].split('.s');parts[0]=`${prefix}.s${sessionId}`;const updatedParts=parts.map((part,index)=>{if(index===0){return part;} if(part.startsWith('o')){return`o${sessionNumber}`;} if(part.startsWith('g')){return`g${sessionEngaged}`;} if(part.startsWith('t')){return`t${sessionId}`;} if(part.startsWith('j')){return`j${joinTimer}`;} return part;});newSessionCookieId=updatedParts.join('$');}else{const cookieParts=originalSessionCookieId.split('.');cookieParts[2]=sessionId;cookieParts[3]='1';cookieParts[4]='0';cookieParts[5]=sessionId;cookieParts[6]='0';newSessionCookieId=cookieParts.join('.');} CookiesVx.set(gaCookieName,newSessionCookieId);} function utmsToString(utmParams={}){return new URLSearchParams({'utm_source':utmParams.source||alcs,'utm_campaign':utmParams.name||alcn,'utm_medium':utmParams.medium||'cpl','utm_term':utmParams.term||'',}).toString();} function shouldResetUserByFeatureActivationDate(initialDate,options={}){const{duration=30,baseProb=0.17,maxProb=1,forceResetAfter=30}=options;const MS_PER_DAY=1000*60*60*24;const start=new Date(initialDate).getTime();if(!start)return true;const now=Date.now();const daysPassed=Math.floor((now-start)/MS_PER_DAY);if(daysPassed>=forceResetAfter)return true;const growthPerDay=(maxProb-baseProb)/(duration-1);const prob=baseProb+(growthPerDay*Math.min(daysPassed,duration-1));return Math.random(){return sendNewUser(measurementId,utmParams);});await Promise.all(promises);const ONE_DAY=24*60*60;CookiesVx.set(voxus_key+'_already_reset_user',true,{domain:'.'+__domain__,expires:ONE_DAY});noNewUserResetReason='sent';} function sendSessionStartMpHit(advertiserId,measurementId){if(advertiserId!=1904||typeof observerController!=='object'||!observerController.observedDomains||!observerController.observedRequests){return;} const domain='server-side-tagging-o5in4ns5xq-uc.a.run.app/g/collect';if(!observerController.observedDomains[domain]){VxAsyncWrapper.setTimeout(()=>sendSessionStartMpHit(advertiserId),200);return;} const observedRequests=observerController.observedRequests[domain];if(observedRequests.length===0){return;} let params=getUrlParams(observedRequests[0]);params._s=1;params._ss=1;const queryString=Object.keys(params).map(key=>key+'='+params[key]).join('&');const url='https://'+domain+'?'+queryString;fetch(url,{method:'GET',mode:'no-cors'}).catch((error)=>{vxLogger.debug("Error in `sendSessionStartMpHit` for advertiser:",client_id,error);vxLogger.trace(error.stack);});CookiesVx.set(voxus_key+'ss_sent',true,{domain:'.'+__domain__,expires:addMinutesToDate(new Date,30).toGMTString()});} function getUrlParams(urlString){const url=new URL(urlString);const params=new URLSearchParams(url.search);const paramsObject={};params.forEach((value,key)=>{paramsObject[key]=value;});return paramsObject;} function sendNewUser(measurementId,utmParams){if(!measurementId){measurementId=getFixedMeasurementId();} const gaUrl='https://www.google-analytics.com/g/collect';const clientId=generateNewCid();updateClientGaCookie(clientId);const sessionId=generateSid();updateCookieSessionId(sessionId,measurementId);let currentPageUrl=window.location.href;const utmParamsName=["utm_source","utm_campaign","utm_medium","utm_term"];const hasUtmParam=utmParamsName.some(utmParam=>currentPageUrl.includes(utmParam));const completeUtmParams=utmsToString(utmParams);if(!hasUtmParam){if(currentPageUrl.includes('?')){currentPageUrl+=`&${completeUtmParams}`;} else{currentPageUrl+=`?${completeUtmParams}`;}} const encodedCurrentPageUrl=encodeURIComponent(currentPageUrl);const payload={v:2,tid:measurementId,npa:0,dma:0,tag_exp:0,cid:clientId,ul:navigator.language.toLowerCase(),sr:window.screen.availWidth+'x'+window.screen.availHeight,uaa:"x86",uab:"64",uafvl:getGAUserAgent(),uamb:0,uam:"",uap:navigator.userAgentData?.platform??"unknown",uapv:"15.0.0",uaw:0,are:1,frm:0,pscdl:"noapi",_eu:"AAAI",_s:1,sid:sessionId,sct:1,seg:0,dl:encodedCurrentPageUrl,dt:document.title,en:"page_view",_fv:1,_nsi:1,_ss:1,tfd:generateRandomTfd()};const queryString=Object.keys(payload).map(key=>key+'='+payload[key]).join('&');const finalUrl=gaUrl+'?'+queryString;fetch(finalUrl,{method:'GET'}).then(response=>{if(client_id==='2377'||client_id==='2276'){sendToLoggly({type:'new_user_hit',pageview:window.location.href,status:response.status});}}).catch(error=>{vxLogger.debug("Error in `sendNewUser` for advertiser: ",client_id,error);vxLogger.trace(error.stack);});} function sessionChanged(currentSessionId){try{if(localStorage.getItem('sessionId')!==currentSessionId){localStorage.setItem('sessionId',currentSessionId);return true;} return false;}catch(e){vxLogger.debug("Error in `sessionChanged` for advertiser: ",client_id,e);vxLogger.trace(e.stack);return false;}} function getSearchParam(paramName){try{const params=new URL(window.location.href).searchParams;return params.get(paramName);}catch(error){vxLogger.debug("Error in `getSearchParam` for advertiser: ",client_id,error);vxLogger.trace(error.stack);return null;}} async function fetchVtexSession(){try{const response=await fetch('/api/sessions?items=*');return await response.json();}catch(error){vxLogger.debug("Error in `fetchVtexSession` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}} async function sendUtmsToVtexCheckout(utms){const form=await vtexjs?.checkout?.getOrderForm();if(!form){return;} const marketingData={utmSource:utms.source,utmMedium:utms.medium,utmCampaign:utms.name,};const orderformResponse=await vtexjs?.checkout?.sendAttachment('marketingData',marketingData);await sendToLoggly({type:'vtex_form',form:orderformResponse,url:window.location.href.replace("#",""),transaction_id:form.orderFormId,});} function isOnVtexCheckout(){return hasCustomization('vtex_hit')&&window.location.pathname.includes('checkout');} function getOSDetails(){let userAgent=navigator.userAgent;let platform=navigator.platform;let iosPlatforms=['iPhone','iPad','iPod'];let os="Unknown";let version="Unknown";if(/Android/.test(userAgent)){os="Android";let match=userAgent.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))?/);if(match){version=`${match[1]}.${match[2]||0}.${match[3]||0}`;}}else if(iosPlatforms.indexOf(platform)!==-1||/iPad|iPhone|iPod/.test(userAgent)){os="iOS";let match=userAgent.match(/OS (\d+)(?:_(\d+))?(?:_(\d+))?/);if(match){version=`${match[1]}.${match[2]||0}.${match[3]||0}`;}}else if(/Mac/.test(platform)){os="MacOS";}else if(/Win/.test(platform)){os="Windows";}else if(/Linux/.test(platform)){os="Linux";} return{os,version};} async function getVerifyTrackData(advertiserId,cookieId,isIpa){try{if(!hasCustomization('cached_verify_requests')||typeof cachedVerifyRequest==="undefined"||cachedVerifyRequest===null){return await fetchVerifyTrackingData(advertiserId,cookieId,isIpa);}}catch(error){vxLogger.debug("Error in `getVerifyTrackData` with non-cached request for advertiser: ",client_id,error);vxLogger.trace(error.stack);return{};} if(!cachedVerifyRequest.queue[advertiserId]){cachedVerifyRequest.queue[advertiserId]={};cachedVerifyRequest.resolved[advertiserId]={};} const cacheKey=isIpa?"ipa_true":"ipa_false";if(cachedVerifyRequest.resolved[advertiserId][cacheKey]){return cachedVerifyRequest.resolved[advertiserId][cacheKey];} if(cachedVerifyRequest.queue[advertiserId][cacheKey]){return await cachedVerifyRequest.queue[advertiserId][cacheKey];} cachedVerifyRequest.queue[advertiserId][cacheKey]=fetchVerifyTrackingData(advertiserId,cookieId,isIpa).then(response=>{cachedVerifyRequest.resolved[advertiserId][cacheKey]=response;delete cachedVerifyRequest.queue[advertiserId][cacheKey];return response;}).catch(error=>{delete cachedVerifyRequest.queue[advertiserId][cacheKey];vxLogger.debug("Error in `getVerifyTrackData` while fetching cached request for advertiser: ",client_id,error);vxLogger.trace(error.stack);return{};});return await cachedVerifyRequest.queue[advertiserId][cacheKey];} function fetchVerifyTrackingData(advertiserId,cookieId,isIpa){return new Promise((resolve,reject)=>{const xhr=new XMLHttpRequest();const BASE_URL="https://api.voxus.tv";const url=`${BASE_URL}/verify/?adv_id=${advertiserId}&ck_id=${cookieId}${isIpa?"&ipa=true":""}`;xhr.open("GET",url,true);xhr.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");xhr.onreadystatechange=function(){if(xhr.readyState===4){if(xhr.status>=200&&xhr.status<300){try{const jsonResponse=JSON.parse(xhr.responseText);resolve(jsonResponse);}catch(e){vxLogger.debug("Error in `fetchVerifyTrackingData` for advertiser: ",client_id,e);vxLogger.trace(e.stack);reject(new Error("Erro ao parsear JSON"));}}else{vxLogger.debug("Error in `fetchVerifyTrackingData` with bad HTTP status code for advertiser: ",client_id,xhr.status);reject(new Error(`Erro HTTP:${xhr.status}`));}}};xhr.onerror=function(){vxLogger.debug("Network error in `fetchVerifyTrackingData` for advertiser: ",client_id);reject(new Error("Erro de rede"));};xhr.send();});} function areFunctionsAvailable(...functionNames){return functionNames.every(fn=>typeof window[fn]==='function');} function getDatalayerTransactionId(datalayerName='dataLayer'){const gaEvent=window[datalayerName]?.find((item)=>item?.event==='purchase');if(!gaEvent){return;} return gaEvent?.['ecommerce']?.transaction_id;} function listenUrlChangesUntil(targetPath,callback){if(!targetPath||!callback){return;} if(window.location.pathname===targetPath){callback();} window.addEventListener('popstate',function(){if(window.location.pathname===targetPath){callback();}});} async function getLastImpressionTimestamp(){return ismobile?await getMobileLastImpressionTimestamp():getDesktopLastImpressionTimestamp();} function getDesktopLastImpressionTimestamp(){return{'time':parseInt(CookiesVx.get('voxus_last_impression_timestamp_'+client_id),10),'campaign':'Not implemented','crtv':'Not implemented'}} async function getMobileLastImpressionTimestamp(){const response=await getVerifyTrackData(client_id,cookie_id,false);if(!response||!response.data||response.data.length===0){return null;} const latestItem=response.data.reduce((latest,current)=>{const latestDate=new Date(latest?.date);const currentDate=new Date(current?.date);if(isNaN(currentDate.getTime()))return latest;if(isNaN(latestDate.getTime()))return current;return currentDate>latestDate?current:latest;});const effective=new Date(latestItem.dateTz||latestItem.date);return{'time':Math.floor(effective.getTime()/1000),'campaign':latestItem.campaign,'creative':latestItem.crtv,};} function normalizeTimestampInSeconds(timestamp){timestamp=Number(timestamp);if(!Number.isFinite(timestamp))return null;const MS_THRESHOLD=1e12;if(timestamp>MS_THRESHOLD){timestamp=Math.floor(timestamp/1000);} return timestamp;} function setLastImpressionTimestampCookie(timestamp){const normalizedTimestamp=normalizeTimestampInSeconds(timestamp);if(!normalizedTimestamp)return;const cookieKey='voxus_last_impression_timestamp_'+client_id;const thirtyDays=60*60*24*30;CookiesVx.set(cookieKey,normalizedTimestamp,{domain:'.'+__domain__,expires:thirtyDays});} function initializeInternalGtag(){if(algs!=null){return;} if(typeof gtag!="undefined"){algs=gtag;}else if(hasCustomization('multi_data_layer')){algs=gtagFunctionFactory();}else{window.dataLayer=window.dataLayer||[];function gtag(){dataLayer.push(arguments);} algs=gtag;}} async function repeatWithDelay(count,delayMs,sendFn,extraDelays=[]){for(let i=0;isetTimeout(resolve,delay));}}} function sendAdobePageView(params){const ADOBE_PAGE_PARAM="pageURL";const ADOBE_PAGE_PARAM2="eVar90";const ADOBE_UTM_PARAM="eVar14";const ADOBE_JUMP_PARAM="eVar15";const utmString=":"+ params["medium"]+":"+ params["source"]+":"+ params["name"]+":";const url=new URL(window.location.href);url.searchParams.set("utm_campaign",params.name);url.searchParams.set("utm_source",params.source);url.searchParams.set("utm_medium",params.medium);if(params.jumpid){url.searchParams.set("jumpid",params.jumpid);} if(typeof window.s_c_il['1']?.t!=='function'){return;} const adobeHitObj={[ADOBE_PAGE_PARAM]:url.toString(),[ADOBE_PAGE_PARAM2]:url.toString(),[ADOBE_UTM_PARAM]:utmString,};if(params.jumpid){adobeHitObj[ADOBE_JUMP_PARAM]=params.jumpid;} window.s_c_il['1'].t(adobeHitObj);} function getSessionId(measurementId=null){if(client_id==='2961'){return CookiesVx.get('rl_session')} const gaData=measurementId?getGaSessionCookieData(measurementId):null;let session=gaData?.sessionId||null;if(!session&&hasCustomization("vtex_io")){session=CookiesVx.get("VtexRCSessionIdv7")||null;} return session;} function getUserId(measurementId=null){const gaData=measurementId?getGaSessionCookieData(measurementId):null;if(gaData){return gaData?.userId;} return thisip;} function decodeURLComponentEscaped(url){return decodeURIComponent(escape(url));} (function(global,undefined){'use strict';var factory=function(window){if(typeof window.document!=='object'){throw new Error('CookiesVx.js requires a `window` with a `document` object');} var CookiesVx=function(key,value,options){return arguments.length===1?CookiesVx.get(key):CookiesVx.set(key,value,options);};CookiesVx._document=window.document;CookiesVx._cacheKeyPrefix='cookey.';CookiesVx._maxExpireDate=new Date('Fri, 31 Dec 9999 23:59:59 UTC');CookiesVx.defaults={path:'/',secure:true,samesite:'None'};CookiesVx.get=function(key){if(CookiesVx._cachedDocumentCookie!==CookiesVx._document.cookie){CookiesVx._renewCache();} var value=CookiesVx._cache[CookiesVx._cacheKeyPrefix+key];return value===undefined?undefined:decodeURIComponent(value);};CookiesVx.set=function(key,value,options){options=CookiesVx._getExtendedOptions(options);options.expires=CookiesVx._getExpiresDate(value===undefined?-1:options.expires);CookiesVx._document.cookie=CookiesVx._generateCookieString(key,value,options);return CookiesVx;};CookiesVx.expire=function(key,options){return CookiesVx.set(key,undefined,options);};CookiesVx._getExtendedOptions=function(options){return{path:options&&options.path||CookiesVx.defaults.path,domain:options&&options.domain||CookiesVx.defaults.domain,expires:options&&options.expires||CookiesVx.defaults.expires,secure:options&&options.secure!==undefined?options.secure:CookiesVx.defaults.secure,samesite:options&&options.samesite!==undefined?options.samesite:CookiesVx.defaults.samesite};};CookiesVx._isValidDate=function(date){return Object.prototype.toString.call(date)==='[object Date]'&&!isNaN(date.getTime());};CookiesVx._getExpiresDate=function(expires,now){now=now||new Date();if(typeof expires==='number'){expires=expires===Infinity?CookiesVx._maxExpireDate:new Date(now.getTime()+expires*1000);}else if(typeof expires==='string'){expires=new Date(expires);} if(expires&&!CookiesVx._isValidDate(expires)){throw new Error('`expires` parameter cannot be converted to a valid Date instance');} return expires;};CookiesVx._generateCookieString=function(key,value,options){key=key.replace(/[^#$&+\^`|]/g,encodeURIComponent);key=key.replace(/\(/g,'%28').replace(/\)/g,'%29');value=(value+'').replace(/[^!#$&-+\--:<-\[\]-~]/g,encodeURIComponent);options=options||{};var cookieString=key+'='+value;cookieString+=options.path?';path='+options.path:'';cookieString+=options.domain?';domain='+options.domain:'';cookieString+=options.expires?';expires='+options.expires.toUTCString():'';cookieString+=options.secure?';secure':'';function shouldSendSameSiteNone(useragent){return!isSameSiteNoneIncompatible(useragent);} function isSameSiteNoneIncompatible(useragent){return hasWebKitSameSiteBug(useragent)||dropsUnrecognizedSameSiteCookies(useragent);} function hasWebKitSameSiteBug(useragent){return isIosVersion(12,useragent)||(isMacosxVersion(10,14,useragent)&&(isSafari(useragent)||isMacEmbeddedBrowser(useragent)));} function dropsUnrecognizedSameSiteCookies(useragent){if(isUcBrowser(useragent)){return!isUcBrowserVersionAtLeast(12,13,2,useragent);} return isChromiumBased(useragent)&&isChromiumVersionAtLeast(51,useragent)&&!isChromiumVersionAtLeast(67,useragent);} function isIosVersion(major,useragent){const regex=/\(iP.+; CPU .*OS (\d+)[_\d]*.*\) AppleWebKit\//g;const match=useragent.match(regex);return match&&match[0]==major;} function isMacosxVersion(major,minor,useragent){const regex=/\(Macintosh;.*Mac OS X (\d+)_(\d+)[_\d]*.*\) AppleWebKit\//g;const match=useragent.match(regex);return match&&(match[0]==major)&&(match[1]==minor);} function isSafari(useragent){const safari_regex=/Version\/.* Safari\//g;return safari_regex.test(useragent)&&!isChromiumBased(useragent);} function isMacEmbeddedBrowser(useragent){const regex=/^Mozilla\/[\.\d]+ \(Macintosh;.*Mac OS X [_\d]+\) AppleWebKit\/[\.\d]+ \(KHTML, like Gecko\)$/g;return regex.test(useragent);} function isChromiumBased(useragent){const regex=/Chrom(e|ium)/g;return regex.test(useragent);} function isChromiumVersionAtLeast(major,useragent){const regex=/Chrom[^ \/]+\/(\d+)[\.\d]* /g;const version=useragent.match(regex)[0];return version>=major;} function isUcBrowser(useragent){const regex=/UCBrowser\//g;return regex.test(useragent);} function isUcBrowserVersionAtLeast(major,minor,build,useragent){const regex=/UCBrowser\/(\d+)\.(\d+)\.(\d+)[\.\d]* /g;const major_version=useragent.match(regex)[0];const minor_version=useragent.match(regex)[1];const build_version=useragent.match(regex)[2];if(major_version!=major){return major_version>major;} if(minor_version!=minor){return minor_version>minor;} return build_version>=build;} if(shouldSendSameSiteNone(window.navigator.userAgent)){cookieString+=';SameSite='+options.samesite+'';} return cookieString;};CookiesVx._getCacheFromString=function(documentCookie){var cookieCache={};var cookiesArray=documentCookie?documentCookie.split('; '):[];for(var i=0;i>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+this._keyStr.charAt(s)+this._keyStr.charAt(o)+this._keyStr.charAt(u)+this._keyStr.charAt(a)}return t},decode:function(e){var t="";var n,r,i;var s,o,u,a;var f=0;e=e.replace(/[^A-Za-z0-9+/=]/g,"");while(f>4;r=(o&15)<<4|u>>2;i=(u&3)<<6|a;t=t+String.fromCharCode(n);if(u!=64){t=t+String.fromCharCode(r)}if(a!=64){t=t+String.fromCharCode(i)}}t=vxencd._utf8_decode(t);return t},_utf8_encode:function(e){e=e.replace(/rn/g,"n");var t="";for(var n=0;n127&&r<2048){t+=String.fromCharCode(r>>6|192);t+=String.fromCharCode(r&63|128)}else{t+=String.fromCharCode(r>>12|224);t+=String.fromCharCode(r>>6&63|128);t+=String.fromCharCode(r&63|128)}}return t},_utf8_decode:function(e){var t="";var n=0;var r=c1=c2=0;while(n191&&r<224){c2=e.charCodeAt(n+1);t+=String.fromCharCode((r&31)<<6|c2&63);n+=2}else{c2=e.charCodeAt(n+1);c3=e.charCodeAt(n+2);t+=String.fromCharCode((r&15)<<12|(c2&63)<<6|c3&63);n+=3}}return t}} var alcs='voxusmediamanager';var alcn='voxus';var alsd='cpl';var st='set';var sd='send';var cs='campaignSource';var cn='campaignName';if(CookiesVx.get(voxus_key+'_campaign_')!=null){alcn='campaign_'+client_id+'_'+CookiesVx.get(voxus_key+'_campaign_');} function getParameterByNameVx__(name){name=name.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var regex=new RegExp("[\\?&]"+name+"=([^&#]*)"),results=regex.exec(location.search);return results===null?"":decodeURIComponent(results[1].replace(/\+/g," "));} function hasAnyQueryStringNameParamLike(name){const params=new URLSearchParams(location.search);const names=typeof name==='string'?[name]:name;for(let i=0;i0){if(getParameterByNameVx__("utm_campaign").split('_').length==3){CookiesVx.set(voxus_key+"_campaign_",getParameterByNameVx__("utm_campaign").split('_')[2],{domain:'.'+__domain__,expires:Infinity});} else{CookiesVx.set(voxus_key+"_campaign_",'-1',{domain:'.'+__domain__,expires:Infinity});}}} if(getParameterByNameVx__('utm_source')=='voxusmediamanager'){CookiesVx.set(voxus_key+"_adinter_pip",'true',{domain:'.'+__domain__,expires:24*60*60});adinter=true;utmInThisPage=true;if(getParameterByNameVx__("utm_campaign").length>0){if(getParameterByNameVx__("utm_campaign").split('_').length==3){CookiesVx.set(voxus_key+"_campaign_",getParameterByNameVx__("utm_campaign").split('_')[2],{domain:'.'+__domain__,expires:Infinity});} else{CookiesVx.set(voxus_key+"_campaign_",'-1',{domain:'.'+__domain__,expires:Infinity});}}} if(getParameterByNameVx__('utm_medium')!=""){localStorage.setItem(voxus_key+"_medium",getParameterByNameVx__("utm_medium"));} if(getParameterByNameVx__('utm_source')!=""){localStorage.setItem(voxus_key+"_source",getParameterByNameVx__("utm_source"));} if(getParameterByNameVx__('utm_content')!=""){localStorage.setItem(voxus_key+"_content",getParameterByNameVx__("utm_content"));} if(getParameterByNameVx__('utm_campaign')!=""){localStorage.setItem(voxus_key+"_campaign",getParameterByNameVx__("utm_campaign"));} if(getParameterByNameVx__('utm_source')!=""||getParameterByNameVx__('gclid')){if(typeof CookiesVx.get(voxus_key+"_kopid_pip")!="undefined"&&CookiesVx.get(voxus_key+"_kopid_pip")!=""){for(var u15I=0;u15I-1){igvxtst=true;} if(isFromOther()){igvxtst=true;fromOther=true;}else{if(___vx__runCVL==true){if(typeof CookiesVx.get(voxus_key+"_cvl")=="undefined"){var __v=(Math.floor(Math.random()*10)+1);CookiesVx.set(voxus_key+"_cvl",__v,{domain:'.'+__domain__,expires:60*60*24*15});}} if(typeof CookiesVx.get(voxus_key+"_id")!="undefined"){cookie_id=CookiesVx.get(voxus_key+"_id");} if(CookiesVx.get(voxus_keypip+"_pipcluster")!=""&&typeof CookiesVx.get(voxus_keypip+"_pipcluster")!="undefined"){pipcluster=CookiesVx.get(voxus_keypip+"_pipcluster");} if(CookiesVx.get(voxus_key+"_voxus_testing")=="true"){igvxtst=true;} if(CookiesVx.get(voxus_key+"_converted_gl")=="true"){converted_gl=client_id*12;} if(CookiesVx.get(voxus_key+"_kopid_pip")!=""&&typeof CookiesVx.get(voxus_key+"_kopid_pip")!="undefined"){if(CookiesVx.get(voxus_key+"_inter_view")!="true"){} kopid=true;kopidCooked=true;creativekaoq=CookiesVx.get(voxus_key+"_kopid_pip");var sgotasdkaoqsplit=creativekaoq.split("-");if(sgotasdkaoqsplit.length>1){sgotasdkaoq=sgotasdkaoqsplit[1];}} if(CookiesVx.get(voxus_key+"_kopid_uh_pip")!=""&&typeof CookiesVx.get(voxus_key+"_kopid_uh_pip")!="undefined"){kopiduh=true;kopid=true;} if(CookiesVx.get(voxus_key+"_adinter_pip")=="true"){adinter=true;} if(CookiesVx.get(voxus_key+"_ignore_full_ugi")=="true"){sent_usubida=true;} if(getParameterByNameVx__('voxus_testing')==1){CookiesVx.set(voxus_key+"_voxus_testing",'true',{domain:'.'+__domain__,expires:43200*60*24*365*20});igvxtst=true;} if(CookiesVx.get(voxus_key+"_ignore")=="true"){igvxtst=true;} function setIgnore(){CookiesVx.set(voxus_key+"_ignore",'true',{domain:'.'+__domain__,expires:60*60*24});CookiesVx.set(voxus_key+"_ignoreot_full",'true',{domain:'.'+__domain__,expires:60*60*24});igvxtst=true;fromOther=true;kopid=false;CookiesVx.expire(voxus_key+"_at_pg_ok");} const ipBlockMap=new Map([['1759',['179.136.39.119','45.190.109.158','23.22.146.56']],['2383',['200.183.70.50','200.170.210.162','187.92.77.116']],]);thisip=thisip||CookiesVx.get(voxus_key+"_ip");if(ipBlockMap.has(client_id)&&thisip&&ipBlockMap.get(client_id).includes(thisip)){setIgnore();} const utmSource=getParameterByNameVx__('utm_source');const defaultSourceParams=getDefaultVxSourceParameters();const isVoxusUtm=defaultSourceParams.includes(utmSource);const utmIsEmpty=utmSource=="";const prohibitedQueryParams=['source','partner','parceiro','origem','affiliate','afiliado'];if(!(utmIsEmpty||isVoxusUtm)&&hasAnyQueryStringNameParamLike(prohibitedQueryParams)){setIgnore();if(utmSource=='LIVELOHOPE'){CookiesVx.set(voxus_key+'_block_full','true',{expires:addDaysToDate(new Date,1)});}} if(getParameterByNameVx__('gclid')!=""&&getParameterByNameVx__('gclid')!="voxusmediamanager"){setIgnore();if(client_id==='385'&&typeof addXandrPixel==='function'){addXandrPixel(40083831);}} if(getParameterByNameVx__('fbclid')!=""){setIgnore();} for(var i=0;i0)||enterpriseId!=0)&&alihuadsanw==false&&!isOnGaHitDelay&&isicgt==false&&lswf==false&&typeof isPageNotRestricted==='function'&&isPageNotRestricted()&&!isBlocked);if((client_id==2638||client_id==2324)&&alihuadsa==0&&!sendHit&&kopid&&!fromOther){sendToLoggly({type:"ga_miss_hit",pageview:window.location.href.replace("#",''),data:{sgarqRun,usubidaPages,enterpriseId,alihuadsanw,isOnGaHitDelay,isicgt,lswf,isBlocked,restricted:isPageNotRestricted(),ignore:!!CookiesVx.get(voxus_key+"_ignore_full_ugi")}});} if(sendHit){if(typeof sgotasd=='object'){if(enterpriseId==0&&sgotasd!=null&&sgotasd.length>0&&typeof(sgotasd[0])!='undefined'&&sgotasd[0].length>0&&sgotasd[0][1]!=null){alcn='campaign_'+client_id+'_'+sgotasd[0][1];}} var urlOk=true;if(CookiesVx.get(voxus_key+"_at_pg_ok")!="true"){var url=window.location.href.split("?");if(url.length>1&&window.location.href.indexOf('utm_expid')===-1){} for(var pgok=0;pgok0){return;}}else{var hasUtms=false;var campaignsUtms=CAMPAIGNS_ENTERPRISE;if(typeof campaignsUtms!="undefined"&&campaignsUtms!=null){var campaignId=CookiesVx.get(voxus_key+"_cp_ent");for(i in campaignsUtms){if(i==campaignId){alcn=campaignsUtms[i].utm_campaign;alcs=campaignsUtms[i].utm_source;alcm=campaignsUtms[i].utm_medium;alcc=campaignsUtms[i].utm_content;hasUtms=true;}}} if(!hasUtms){return false;}} sgarqRun=false;kiphouYiasO=[];var urlTrackerVx2='https://api.voxus.tv/verify/c.php?adv_id='+client_id;var httptrk2=new XMLHttpRequest();httptrk2.open("GET",urlTrackerVx2,true);httptrk2.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httptrk2.send();httptrk2.onreadystatechange=function(){if(httptrk2.readyState!=4||httptrk2.status!=200){gaNotSentReason=`http-state-readyState:${httptrk2.readyState}-status:${httptrk2.status}`;return;} var response=JSON.parse(httptrk2.responseText);if(response==null||response.cv==null||response.cv!==false){gaNotSentReason='response.cv' return;} CookiesVx.set(voxus_key+"_assigned",'true',{domain:'.'+__domain__,expires:addMinutesToDate(new Date,30)});if(hasCustomization('vtex_io')){var vtxLocCached=window.location.origin+'/?utm_source='+alcs+'&utm_medium=' +alcm+'&utm_campaign='+alcn;overwriteVtxImplementation(vtxLocCached,alcs);window.dataLayer.push({'originalLocation':vtxLocCached});} if(hasCustomization('ga4_reset_session')){resetGa4Session(getMeasurementIds());} if(hasCustomization("conv_skip")&&isConversionPage()){sendToLoggly({type:"conv_skip",pageview:window.location.href.replace("#",""),tp:thisip});gaNotSentReason='conv-skip';return;} let params=getUtmParametersToSend(alcs,alcm,alcn);if(hasCustomization('new_user_reset')){sendNewUserToAllGaIds(params);} if(hasCustomization('ga_hit')){if(hasCustomization('other_v2')&&!isVoxusLastPaidMedia()){const timestampCookie=CookiesVx.get('voxus_last_impression_timestamp_'+client_id);const activePaidMedia=getActivePaidMedia();if(!activePaidMedia?.time){return;} if(timestampCookie){const cookieDate=(new Date(timestampCookie*1000)).toISOString();sendToLoggly({type:'expire_hit_v3',pageview:window.location.href,activePaidMedia:getActivePaidMedia(),cookie_id:cookie_id,ads:kopid,hasIgnore:CookiesVx.get(voxus_key+"_ignoreot_full"),timestampCookie:cookieDate,});} if(!ismobile){const now=Math.floor(Date.now()/1000);const twentyFourHoursAttrWindowInSeconds=24*60*60;const timePassed=now-activePaidMedia.time;const timeLeft=twentyFourHoursAttrWindowInSeconds-timePassed;if(timeLeft<=0){gaNotSentReason='expire-v3-timeout' return;} CookiesVx.set(voxus_key+'_ignoreot_full','true',{domain:'.'+__domain__,expires:timeLeft});gaNotSentReason='expire-v3-ignore' return;}} initializeInternalGtag();if(hasCustomization('multiple-ga-hits-with-delay')){sendMultipleAnalyticsHitsWithDelays(()=>sendDefaultAnalyticsHit(params));}else if(client_id==='2192'){const STANLEY_MEASUREMENT_IDS=['G-7SQVXS4XQ3','AW-337031149/bcnXCMnv6MgZEO3f2qAB','MC-44QG4TGF83'];listenDataLayerChangesUntil(item=>item&&item[0]==='config').then(()=>{sendMultipleAnalyticsHitsWithDelays(()=>sendDefaultAnalyticsHit(params,STANLEY_MEASUREMENT_IDS));});}else{sendDefaultAnalyticsHit(params);} alihuadsa=true;alihuadsanw=true;if(hasCustomization("conv_skip")){sendToLoggly({type:"conv_not_skip",pageview:window.location.href.replace("#",""),tp:thisip,});return;} if(!hasCustomization('ga-hits-with-no-delay')){CookiesVx.set(voxus_key+"_ignore_full_ugi",'true',{domain:'.'+__domain__,expires:addMinutesToDate(new Date,1)});}} if(hasCustomization('affk_hit')){const cookieKey=voxus_key+'_affk_hit';if(!CookiesVx.get(cookieKey)){const affkUrl='https://ads.alfa.bet.br/xc93c01ca?cb='+Date.now()+"&tr_src=voxus_test";addPixel(affkUrl);CookiesVx.set(cookieKey,'true',{domain:"."+__domain__,expires:addDaysToDate(new Date(),1)});}} if(hasCustomization('mtm_hit')&&_paq){const url=new URL(window.location.href);url.searchParams.append('utm_campaign',params.name);url.searchParams.append('utm_source',params.source);url.searchParams.append('utm_medium',params.medium);_paq.push(['setCustomUrl',url.toString()]);_paq.push(['trackPageView']);} if(hasCustomization('vtex_hit')){if(isOnVtexCheckout()){sendUtmsToVtexCheckout(params);} fetch('/api/sessions',{method:'PATCH',headers:{'Content-Type':'application/json',},body:JSON.stringify({"public":{"utm_campaign":{"value":params.name},"utm_medium":{"value":params.medium},"utm_source":{"value":params.source}}}),}).catch((e)=>{vxLogger.debug("Error while firing VTEX Session hit in `sgarq()` for advertiser: ",client_id,e);vxLogger.trace(e.stack);});} if(hasCustomization('amp_hit')&&typeof amplitude==='object'){const identifyObj=new amplitude.Identify();identifyObj.set('utm_campaign',params.name);identifyObj.set('utm_medium',params.medium);identifyObj.set('utm_source',params.source);amplitude.identify(identifyObj);} if(hasCustomization('adobe_hit')){sendAdobePageView(params);}} function sendMultipleAnalyticsHitsWithDelays(sendFn,delays=[2000,2000,5000,10000]){(async()=>{await repeatWithDelay(delays.length+1,2000,sendFn,delays);})();} function sendDefaultAnalyticsHit(params,measurementIds=null){algs('event','page_view',{campaign:params,send_to:measurementIds||getMeasurementIds()});analyticsAttributionHitsSentOnPage.ga=true;} function isConversionPage(){const allConversionPaths=subusubidaPages.concat(usubidaPages).map((page)=>page.replace("/",""));return allConversionPaths.some((path)=>window.location.pathname.includes(path));} function overwriteVtxImplementation(locationWithVoxusUtm,alcs){var isVtxCached=localStorage.getItem('analytics:session')!=null;if(!isVtxCached) return;var currentCache=localStorage.getItem('analytics:session');var alreadyHasVoxus=currentCache.indexOf('utm_source='+alcs)!=-1;if(alreadyHasVoxus) return;currentCache=JSON.parse(currentCache);currentCache.location=locationWithVoxusUtm;localStorage.setItem('analytics:session',JSON.stringify(currentCache));} function getCustomUtmFromAssociatedAdvertisers(associatedAdvData,originalSource,originalCampaign,originalMedium){let response={source:originalSource,campaign:originalCampaign,medium:originalMedium};if(typeof associatedAdvData=='undefined'){return response;} Object.values(associatedAdvData).forEach(({kaoq,source,campaign,medium})=>{if(kaoq===true){if(typeof source!='undefined'){response.source=source;} if(typeof campaign!='undefined'){response.campaign=campaign;} if(typeof medium!='undefined'){response.medium=medium;}}});return response;} function getAdvertiserCustomGlobalUtm(advertiser_id,alcs,alcn,alcm){const response={source:alcs,campaign:alcn,medium:alcm,content:'',term:''};if(Object.keys(advWithCustomUtm).length>0){response.source=advWithCustomUtm['utm_source'];response.campaign=advWithCustomUtm['utm_campaign'];response.medium=advWithCustomUtm['utm_medium'];response.content=advWithCustomUtm['utm_content'];response.term=advWithCustomUtm['utm_term'];} return response;} function getUtmParametersToSend(alcs,alcm,alcn){let customUtm=getAdvertiserCustomGlobalUtm(client_id,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;if(typeof associatedAdvData!=='undefined'&&associatedAdvData!==null){customUtm=getCustomUtmFromAssociatedAdvertisers(associatedAdvData,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;} const aditionalCustomParameters={};const customParams=advWithCustomUtm['custom_params'];if(customParams&&Object.keys(customParams).length>0){for(const[key,value]of Object.entries(customParams)){aditionalCustomParameters[key]=value;}} const lastAdSeen=getLastAdSeen();if(Object.keys(adsWithCustomData).length===0||lastAdSeen===''||typeof(adsWithCustomData[lastAdSeen])=='undefined'){return{'source':alcs,'medium':alcm,'name':alcn,'content':customUtm.content,'term':customUtm.term,...aditionalCustomParameters};}else{return{'source':adsWithCustomData[lastAdSeen].source!=''?adsWithCustomData[lastAdSeen].source:alcs,'medium':adsWithCustomData[lastAdSeen].medium!=''?adsWithCustomData[lastAdSeen].medium:alcm,'name':adsWithCustomData[lastAdSeen].name!=''?adsWithCustomData[lastAdSeen].name:alcn,'content':adsWithCustomData[lastAdSeen].content,'term':adsWithCustomData[lastAdSeen].term!=''?adsWithCustomData[lastAdSeen].term:'',...aditionalCustomParameters}}} sgarq=function(){};}else{sgarq=function(){};}} checkStatisticsConvUser();}}} if(!hasCustomization('disable_set_interval')){VxAsyncWrapper.setInterval(verifyPage,1000);} if(isFromOther()){return false;} sgarq=function() {var creativesUtms=[];if(clientDomainWl.length==0){clientDomain=clientDomain.replace("www.","");if(window.location.href.toLowerCase().indexOf(clientDomain.toLowerCase())===-1){return;}}else{var domainBlocked=true;for(bl=0;bl0)||enterpriseId!=0)&&alihuadsanw==false&&!isOnGaHitDelay&&isicgt==false&&lswf==false&&typeof isPageNotRestricted==='function'&&isPageNotRestricted()&&!isBlocked);if((client_id==2638||client_id==2324)&&alihuadsa==0&&!sendHit&&kopid&&!fromOther){sendToLoggly({type:"ga_miss_hit",pageview:window.location.href.replace("#",''),data:{sgarqRun,usubidaPages,enterpriseId,alihuadsanw,isOnGaHitDelay,isicgt,lswf,isBlocked,restricted:isPageNotRestricted(),ignore:!!CookiesVx.get(voxus_key+"_ignore_full_ugi")}});} if(sendHit){if(typeof sgotasd=='object'){if(enterpriseId==0&&sgotasd!=null&&sgotasd.length>0&&typeof(sgotasd[0])!='undefined'&&sgotasd[0].length>0&&sgotasd[0][1]!=null){alcn='campaign_'+client_id+'_'+sgotasd[0][1];}} var urlOk=true;if(CookiesVx.get(voxus_key+"_at_pg_ok")!="true"){var url=window.location.href.split("?");if(url.length>1&&window.location.href.indexOf('utm_expid')===-1){} for(var pgok=0;pgok0){return;}}else{var hasUtms=false;var campaignsUtms=CAMPAIGNS_ENTERPRISE;if(typeof campaignsUtms!="undefined"&&campaignsUtms!=null){var campaignId=CookiesVx.get(voxus_key+"_cp_ent");for(i in campaignsUtms){if(i==campaignId){alcn=campaignsUtms[i].utm_campaign;alcs=campaignsUtms[i].utm_source;alcm=campaignsUtms[i].utm_medium;alcc=campaignsUtms[i].utm_content;hasUtms=true;}}} if(!hasUtms){return false;}} sgarqRun=false;kiphouYiasO=[];var urlTrackerVx2='https://api.voxus.tv/verify/c.php?adv_id='+client_id;var httptrk2=new XMLHttpRequest();httptrk2.open("GET",urlTrackerVx2,true);httptrk2.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httptrk2.send();httptrk2.onreadystatechange=function(){if(httptrk2.readyState!=4||httptrk2.status!=200){gaNotSentReason=`http-state-readyState:${httptrk2.readyState}-status:${httptrk2.status}`;return;} var response=JSON.parse(httptrk2.responseText);if(response==null||response.cv==null||response.cv!==false){gaNotSentReason='response.cv' return;} CookiesVx.set(voxus_key+"_assigned",'true',{domain:'.'+__domain__,expires:addMinutesToDate(new Date,30)});if(hasCustomization('vtex_io')){var vtxLocCached=window.location.origin+'/?utm_source='+alcs+'&utm_medium=' +alcm+'&utm_campaign='+alcn;overwriteVtxImplementation(vtxLocCached,alcs);window.dataLayer.push({'originalLocation':vtxLocCached});} if(hasCustomization('ga4_reset_session')){resetGa4Session(getMeasurementIds());} if(hasCustomization("conv_skip")&&isConversionPage()){sendToLoggly({type:"conv_skip",pageview:window.location.href.replace("#",""),tp:thisip});gaNotSentReason='conv-skip';return;} let params=getUtmParametersToSend(alcs,alcm,alcn);if(hasCustomization('new_user_reset')){sendNewUserToAllGaIds(params);} if(hasCustomization('ga_hit')){if(hasCustomization('other_v2')&&!isVoxusLastPaidMedia()){const timestampCookie=CookiesVx.get('voxus_last_impression_timestamp_'+client_id);const activePaidMedia=getActivePaidMedia();if(!activePaidMedia?.time){return;} if(timestampCookie){const cookieDate=(new Date(timestampCookie*1000)).toISOString();sendToLoggly({type:'expire_hit_v3',pageview:window.location.href,activePaidMedia:getActivePaidMedia(),cookie_id:cookie_id,ads:kopid,hasIgnore:CookiesVx.get(voxus_key+"_ignoreot_full"),timestampCookie:cookieDate,});} if(!ismobile){const now=Math.floor(Date.now()/1000);const twentyFourHoursAttrWindowInSeconds=24*60*60;const timePassed=now-activePaidMedia.time;const timeLeft=twentyFourHoursAttrWindowInSeconds-timePassed;if(timeLeft<=0){gaNotSentReason='expire-v3-timeout' return;} CookiesVx.set(voxus_key+'_ignoreot_full','true',{domain:'.'+__domain__,expires:timeLeft});gaNotSentReason='expire-v3-ignore' return;}} initializeInternalGtag();if(hasCustomization('multiple-ga-hits-with-delay')){sendMultipleAnalyticsHitsWithDelays(()=>sendDefaultAnalyticsHit(params));}else if(client_id==='2192'){const STANLEY_MEASUREMENT_IDS=['G-7SQVXS4XQ3','AW-337031149/bcnXCMnv6MgZEO3f2qAB','MC-44QG4TGF83'];listenDataLayerChangesUntil(item=>item&&item[0]==='config').then(()=>{sendMultipleAnalyticsHitsWithDelays(()=>sendDefaultAnalyticsHit(params,STANLEY_MEASUREMENT_IDS));});}else{sendDefaultAnalyticsHit(params);} alihuadsa=true;alihuadsanw=true;if(hasCustomization("conv_skip")){sendToLoggly({type:"conv_not_skip",pageview:window.location.href.replace("#",""),tp:thisip,});return;} if(!hasCustomization('ga-hits-with-no-delay')){CookiesVx.set(voxus_key+"_ignore_full_ugi",'true',{domain:'.'+__domain__,expires:addMinutesToDate(new Date,1)});}} if(hasCustomization('affk_hit')){const cookieKey=voxus_key+'_affk_hit';if(!CookiesVx.get(cookieKey)){const affkUrl='https://ads.alfa.bet.br/xc93c01ca?cb='+Date.now()+"&tr_src=voxus_test";addPixel(affkUrl);CookiesVx.set(cookieKey,'true',{domain:"."+__domain__,expires:addDaysToDate(new Date(),1)});}} if(hasCustomization('mtm_hit')&&_paq){const url=new URL(window.location.href);url.searchParams.append('utm_campaign',params.name);url.searchParams.append('utm_source',params.source);url.searchParams.append('utm_medium',params.medium);_paq.push(['setCustomUrl',url.toString()]);_paq.push(['trackPageView']);} if(hasCustomization('vtex_hit')){if(isOnVtexCheckout()){sendUtmsToVtexCheckout(params);} fetch('/api/sessions',{method:'PATCH',headers:{'Content-Type':'application/json',},body:JSON.stringify({"public":{"utm_campaign":{"value":params.name},"utm_medium":{"value":params.medium},"utm_source":{"value":params.source}}}),}).catch((e)=>{vxLogger.debug("Error while firing VTEX Session hit in `sgarq()` for advertiser: ",client_id,e);vxLogger.trace(e.stack);});} if(hasCustomization('amp_hit')&&typeof amplitude==='object'){const identifyObj=new amplitude.Identify();identifyObj.set('utm_campaign',params.name);identifyObj.set('utm_medium',params.medium);identifyObj.set('utm_source',params.source);amplitude.identify(identifyObj);} if(hasCustomization('adobe_hit')){sendAdobePageView(params);}} function sendMultipleAnalyticsHitsWithDelays(sendFn,delays=[2000,2000,5000,10000]){(async()=>{await repeatWithDelay(delays.length+1,2000,sendFn,delays);})();} function sendDefaultAnalyticsHit(params,measurementIds=null){algs('event','page_view',{campaign:params,send_to:measurementIds||getMeasurementIds()});analyticsAttributionHitsSentOnPage.ga=true;} function isConversionPage(){const allConversionPaths=subusubidaPages.concat(usubidaPages).map((page)=>page.replace("/",""));return allConversionPaths.some((path)=>window.location.pathname.includes(path));} function overwriteVtxImplementation(locationWithVoxusUtm,alcs){var isVtxCached=localStorage.getItem('analytics:session')!=null;if(!isVtxCached) return;var currentCache=localStorage.getItem('analytics:session');var alreadyHasVoxus=currentCache.indexOf('utm_source='+alcs)!=-1;if(alreadyHasVoxus) return;currentCache=JSON.parse(currentCache);currentCache.location=locationWithVoxusUtm;localStorage.setItem('analytics:session',JSON.stringify(currentCache));} function getCustomUtmFromAssociatedAdvertisers(associatedAdvData,originalSource,originalCampaign,originalMedium){let response={source:originalSource,campaign:originalCampaign,medium:originalMedium};if(typeof associatedAdvData=='undefined'){return response;} Object.values(associatedAdvData).forEach(({kaoq,source,campaign,medium})=>{if(kaoq===true){if(typeof source!='undefined'){response.source=source;} if(typeof campaign!='undefined'){response.campaign=campaign;} if(typeof medium!='undefined'){response.medium=medium;}}});return response;} function getAdvertiserCustomGlobalUtm(advertiser_id,alcs,alcn,alcm){const response={source:alcs,campaign:alcn,medium:alcm,content:'',term:''};if(Object.keys(advWithCustomUtm).length>0){response.source=advWithCustomUtm['utm_source'];response.campaign=advWithCustomUtm['utm_campaign'];response.medium=advWithCustomUtm['utm_medium'];response.content=advWithCustomUtm['utm_content'];response.term=advWithCustomUtm['utm_term'];} return response;} function getUtmParametersToSend(alcs,alcm,alcn){let customUtm=getAdvertiserCustomGlobalUtm(client_id,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;if(typeof associatedAdvData!=='undefined'&&associatedAdvData!==null){customUtm=getCustomUtmFromAssociatedAdvertisers(associatedAdvData,alcs,alcn,alcm);alcs=customUtm.source;alcn=customUtm.campaign;alcm=customUtm.medium;} const aditionalCustomParameters={};const customParams=advWithCustomUtm['custom_params'];if(customParams&&Object.keys(customParams).length>0){for(const[key,value]of Object.entries(customParams)){aditionalCustomParameters[key]=value;}} const lastAdSeen=getLastAdSeen();if(Object.keys(adsWithCustomData).length===0||lastAdSeen===''||typeof(adsWithCustomData[lastAdSeen])=='undefined'){return{'source':alcs,'medium':alcm,'name':alcn,'content':customUtm.content,'term':customUtm.term,...aditionalCustomParameters};}else{return{'source':adsWithCustomData[lastAdSeen].source!=''?adsWithCustomData[lastAdSeen].source:alcs,'medium':adsWithCustomData[lastAdSeen].medium!=''?adsWithCustomData[lastAdSeen].medium:alcm,'name':adsWithCustomData[lastAdSeen].name!=''?adsWithCustomData[lastAdSeen].name:alcn,'content':adsWithCustomData[lastAdSeen].content,'term':adsWithCustomData[lastAdSeen].term!=''?adsWithCustomData[lastAdSeen].term:'',...aditionalCustomParameters}}} sgarq=function(){};}else{sgarq=function(){};}} intervalDocumentOnloadVoxusDsp=VxAsyncWrapper.setInterval(function(){if(document.body==null){return;} clearInterval(intervalDocumentOnloadVoxusDsp);var objclk=null;var random=Math.random()*10000000000000000000;checkStatisticsConvUser();if(typeof window.onpopstate=='function'){var onpopstatefunctionvx=window.onpopstate;window.onpopstate=function(){sdloggly(true);checkStatisticsConvUser();onpopstatefunctionvx();}} if(typeof window.addEventListener=='function'){window.addEventListener('hashchange',function(){sdloggly(true);if(typeof reloadPixels=='function'){reloadPixels();} checkStatisticsConvUser();if(typeof checkEnterprise=="function"){checkEnterprise();} for(var i=0;ianalyticsServersReceivedHitsOnPage[id]===true);if(allReceived){observerController.stop();}}catch(error){vxLogger.debug("Error in `stopObservingAfterAllVoxusPageViewEvents` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}} function stopObservingAfterPageViewEvent(urlString,observerController){if(!observerController||typeof observerController.getRequests!=="function"){return;} const requests=observerController.getRequests();if(!Array.isArray(requests)||requests.length===0){return;} try{const event=requests.find(request=>{try{const url=new URL(request);return url.searchParams.has('en')&&url.searchParams.get('en')==='page_view';}catch(error){vxLogger.debug("Error while searching params in `stopObservingAfterPageViewEvent` for advertiser: ",client_id,error);vxLogger.trace(error.stack);return false;}});if(event){observerController.stop();}}catch(error){vxLogger.debug("Error in `stopObservingAfterPageViewEvent` for advertiser: ",client_id,error);vxLogger.trace(error.stack);}} customClickChecking();let previousDataLayerLength=0;function trackClickElements(newDataLayerItem,trackingClickElements){if(!Array.isArray(trackingClickElements)){return;} if(typeof trackedElements['cliques']==='undefined') trackedElements['cliques']={};const trackedElement=newDataLayerItem['gtm.element'];trackingClickElements.forEach(function(trackingElement){if(trackedElement.closest(trackingElement)){if(typeof trackedElements['cliques'][trackingElement]==='undefined'||!trackedElements['cliques'][trackingElement]){trackedElements['cliques'][trackingElement]=true;sdloggly(true);}}});} function dataLayerTracking(trackingElements){if(dataLayer.length===previousDataLayerLength){return{};} const newDataLayerItems=dataLayer.slice(previousDataLayerLength);newDataLayerItems.forEach(function(newDataLayerItem){if(trackingElements['cliques']&&newDataLayerItem.event===('gtm.'+'cli'+'ck')&&typeof newDataLayerItem['gtm.element']!=='undefined'){trackClickElements(newDataLayerItem,trackingElements['cliques'])} if(trackingElements['scroll']&&newDataLayerItem.event==='gtm.scrollDepth'){trackedElements['scroll']=true;sdloggly(true);}});previousDataLayerLength=dataLayer.length;} function startDataLayerTracking() {const trackingElements=JSON.parse("{\"cliques\":[\"button.btn.btn--rounded\"],\"scroll\":true}");initializeTrackedElements(trackingElements);VxAsyncWrapper.setInterval(()=>dataLayerTracking(trackingElements),2000);} function initializeTrackedElements(trackingElements) {for(const key in trackingElements){if(trackingElements.hasOwnProperty(key)){if(Array.isArray(trackingElements[key])){trackedElements[key]={};trackingElements[key].forEach(element=>{trackedElements[key][element]=false;});}else{trackedElements[key]=false;}}}} if(hasCustomization('custom_tracking')){startDataLayerTracking();} function checkStatisticsConvUser(page){if(typeof page=="undefined"){page=false;} if(CookiesVx.get(voxus_key+"_converted")!="true"&&(kopid==true||adinter==true||kopiduh==true)){if(hasCustomization('analytics-multi-tid-voxus-hit-observer')&&typeof observeAllPageViewEventsByMeasurementId==='function'){observeAllPageViewEventsByMeasurementId();} sgarq();} if(CookiesVx.get(voxus_key+"_converted")!="true"&&(kopid==true||adinter==true||kopiduh==true)&&alihuadsa){var objclk=null;if(page===false){page=window.location.href;} for(var i=0;i1){objclk=document.getElementById(idobjclk[1]);}}}} if(objclk!=null){objclk.addEventListener("inter",function(){if(interConversion==false){interConversion=true;sgarq();for(var i=0;ianalyticsServersReceivedHitsOnPage[id]===true);const elapsed=Date.now()-logglyProcessStartDate[methodName];if(allReady||elapsed>=timeout){logglyProcessStartDate[methodName]=null;return false;} VxAsyncWrapper.setTimeout(()=>onReadyFn(),200);return true;} function sdlogglyinter(eventClick,md5Event) {logglyloadvoxus=true;if(typeof force=="undefined"){force=false;} var ignoreThis=false;for(it=0;it-1){ignoreThis=true;}} if(ignoreThis){return;} if(hasCustomization('ga_hit')&&!getFixedMeasurementId()){VxAsyncWrapper.setTimeout(()=>sdlogglyinter(eventClick,md5Event),200);return;} let observedRequests='';if(hasCustomization('analytics_observer')&&typeof observerController==='object'&&observerController.observedDomains&&observerController.observedRequests){const isAllDomainsReady=Object.values(observerController.observedDomains).every(status=>status===true);if(!isAllDomainsReady){VxAsyncWrapper.setTimeout(()=>sdloggly(force),200);return;} observedRequests=Object.values(observerController.observedRequests).flat().join(',')||"";} if(hasCustomization('analytics-multi-tid-voxus-hit-observer')&&waitUntilVoxusHitsOrTimeout(()=>sdlogglyinter(eventClick,md5Event),'logglyinter')){return;} alihuadsa=alihuadsanw;if(alihuadsa==true){alihuadsa=1;}else{alihuadsa=0;} var dateLoggly=new Date();var yearString=dateLoggly.getUTCFullYear()+"";var monthString=(dateLoggly.getUTCMonth()+1)+"";if(monthString.length==1){monthString="0"+monthString;} var dayString=dateLoggly.getUTCDate()+"";if(dayString.length==1){dayString="0"+dayString;} var hourString=dateLoggly.getUTCHours()+"";if(hourString.length==1){hourString="0"+hourString;} var minuteString=dateLoggly.getUTCMinutes()+"";if(minuteString.length==1){minuteString="0"+minuteString;} var secondString=dateLoggly.getUTCSeconds()+"";if(secondString.length==1){secondString="0"+secondString;} var dateLogglyString=yearString+"-"+monthString+"-"+dayString+" "+hourString+":"+minuteString+":"+secondString;var liftStudy=0;if(___vx__runCVL==true){if(typeof CookiesVx.get(voxus_key+"_cvl")!="undefined"){if(CookiesVx.get(voxus_key+"_cvl")==1){liftStudy=1;}}} const measurementId=getFixedMeasurementId();const session=measurementId?getGaSessionCookieData(measurementId)?.sessionId:null;var data={};data.typeinter=eventClick;data.button=md5Event;data.version=sayswho();data.tp=thisip;if(hasCustomization('user_behavior')){let userGaSessionData=getUserSessionData(measurementId);data.session_time=userGaSessionData?userGaSessionData.session_time:-1;data.vx_session_pages_qt=userGaSessionData?userGaSessionData.vx_session_pages_qt:-1;data.has_items_in_cart=hasItemsInDataLayerCart();} data.lftst=liftStudy;data.pageview=window.location.href.replace("#","");data.data=dateLogglyString;data.action='mediamanager';data.usubidaimpression=totalSes;data.kopidcooked=kopidCooked;data.usubidainter=adinter;data.kopidpip=kopid;data.sgotasdkaoq=sgotasdkaoq;data.creative=creativekaoq;data.other=isFromOther();data.otherv2=fromOtherv2;data.recent_conv=CookiesVx.get(voxus_key+"_usubida_tracking");data.ga=alihuadsa;data.ds_hit_sent=analyticsAttributionHitsSentOnPage.ds;data.tf_ds_hit_sent=analyticsAttributionHitsSentOnPage.tfDs;data.ga_not_sent_reason=gaNotSentReason;data.new_user_not_reset_reason=noNewUserResetReason;data.lftst=analyticsAttributionHitsSentOnPage.ga?1:0;data.pipcluster=pipcluster;data.cookie_id=cookie_id;data.mobile=ismobile;data.ignore=igvxtst;data.creative=creativekaoq;data.session=session;if(hasCustomization('analytics_observer')&&observedRequests){data.analytics_requests=observedRequests;} if(hasCustomization('analytics-multi-tid-voxus-hit-observer')){data.rewrite_ip=JSON.stringify(analyticsServersReceivedHitsOnPage);} var protocol=window.location.protocol.replace(":","");var token='27cf9a30-eb89-41a7-ba82-3280d33fb2cf';var urlLoggly=protocol+"://logs-01.loggly.com/inputs/"+token+"/tag/"+protocol+"/";var httploggly=new XMLHttpRequest();httploggly.open("POST",urlLoggly,true);httploggly.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httploggly.send(JSON.stringify(data));httploggly.onreadystatechange=function(){if(httploggly.readyState==4){if(httploggly.status!=200){sdloggly(false);}else{var response=JSON.parse(httploggly.responseText);if(response==null||typeof response.response=="undefined"||response.response!="ok"){sdloggly(false);}}}}} function getOperatingSystem(){let userAgent=navigator.userAgent;let platform=navigator.platform;let macosPlatforms=['Macintosh','MacIntel','MacPPC','Mac68K'];let windowsPlatforms=['Win32','Win64','Windows','WinCE'];let iosPlatforms=['iPhone','iPad','iPod'];let os=null;if(macosPlatforms.indexOf(platform)!==-1){os='Mac OS';}else if(iosPlatforms.indexOf(platform)!==-1){os='iOS';}else if(windowsPlatforms.indexOf(platform)!==-1){os='Windows';}else if(/Android/.test(userAgent)){os='Android';}else if(!os&&/Linux/.test(platform)){os='Linux';} else{os="Unidentified"} return os;} function sdloggly(force) {var ignoreThis=false;for(it=0;it-1){ignoreThis=true;}} if(ignoreThis){return;} if(hasCustomization('ga_hit')&&!getFixedMeasurementId()){VxAsyncWrapper.setTimeout(()=>sdloggly(force),200);return;} let observedRequests='';if(hasCustomization('analytics_observer')&&typeof observerController==='object'&&observerController.observedDomains&&observerController.observedRequests){const isAllDomainsReady=Object.values(observerController.observedDomains).every(status=>status===true);if(!isAllDomainsReady){VxAsyncWrapper.setTimeout(()=>sdloggly(force),200);return;} observedRequests=Object.values(observerController.observedRequests).flat().join(',')||"";} if(hasCustomization('analytics-multi-tid-voxus-hit-observer')&&waitUntilVoxusHitsOrTimeout(()=>sdloggly(force),'sdloggly')){return;} totalLogglys++;if(totalLogglys>=10){return;} logglyloadvoxus=true;if(typeof force=="undefined"){force=false;} alihuadsa=alihuadsanw;if(alihuadsa==true){alihuadsa=1;}else{alihuadsa=0;} if(alihuadsa==0){if(CookiesVx.get(voxus_key+"_ignore_full_ugi")=="true"){alihuadsa=1;}} var dateLoggly=new Date();var yearString=dateLoggly.getUTCFullYear()+"";var monthString=(dateLoggly.getUTCMonth()+1)+"";if(monthString.length==1){monthString="0"+monthString;} var dayString=dateLoggly.getUTCDate()+"";if(dayString.length==1){dayString="0"+dayString;} var hourString=dateLoggly.getUTCHours()+"";if(hourString.length==1){hourString="0"+hourString;} var minuteString=dateLoggly.getUTCMinutes()+"";if(minuteString.length==1){minuteString="0"+minuteString;} var secondString=dateLoggly.getUTCSeconds()+"";if(secondString.length==1){secondString="0"+secondString;} var dateLogglyString=yearString+"-"+monthString+"-"+dayString+" "+hourString+":"+minuteString+":"+secondString;var typeWindow=3;if(window.opener){typeWindow=1;}else if(window.top!==window.self){typeWindow=2;}else{typeWindow=3;} var widthAnalysis=800;var heightAnalysis=800;if(typeof document!="undefined"&&typeof document.documentElement!="undefined"){widthAnalysis=document.documentElement.clientWidth;heightAnalysis=document.documentElement.clientHeight;} var liftStudy=0;if(___vx__runCVL==true){if(typeof CookiesVx.get(voxus_key+"_cvl")!="undefined"){if(CookiesVx.get(voxus_key+"_cvl")==1){liftStudy=1;}}} const measurementId=getFixedMeasurementId();var data={};data.os=getOperatingSystem();if(typeof isNewUser!="undefined"){data.new_user=isNewUser();} if(hasCustomization('custom_conv_id')&&typeof getConvIdForAdvertiser!='undefined'){const conv_id=getConvIdForAdvertiser();if(conv_id){data.conv_id=conv_id;}} const voxus_last_impression_timestamp=CookiesVx.get('voxus_last_impression_timestamp_'+client_id);if(typeof voxus_last_impression_timestamp!=='undefined'){data.voxus_last_impression_timestamp=voxus_last_impression_timestamp;data.voxus_user_return_timestamp=Math.floor(Date.now()/1000);data.voxus_last_entry_before_impression=CookiesVx.get('voxus_last_entry_before_impression');} else{const thirtyDays=60*60*24*30;CookiesVx.set('voxus_last_entry_before_impression',Math.floor(Date.now()/1000),{domain:'.'+__domain__,expires:thirtyDays})} data.index_nck_version=indexNckVersion;if(typeof tagVersion!=='undefined'){data.tag_version=tagVersion;} if(typeof tagSemanticVersion!=='undefined'){data.tag_semversion=tagSemanticVersion;} data.assigned=CookiesVx.get(voxus_key+"_assigned")=='true';if(typeof getUtmParametersToSend==='function'){const utms=getUtmParametersToSend();data.source=utms.source;data.medium=utms.medium;data.campaign=utms.name;} data.width=widthAnalysis;data.height=heightAnalysis;data.tp=thisip;if(hasCustomization('user_behavior')){let userGaSessionData=getUserSessionData(measurementId);data.session_time=userGaSessionData?userGaSessionData.session_time:-1;data.vx_session_pages_qt=userGaSessionData?userGaSessionData.vx_session_pages_qt:-1;data.has_items_in_cart=hasItemsInDataLayerCart();} if(hasCustomization('custom_tracking')&&typeof trackedElements!=='undefined'){data.custom_tracking=trackedElements;} if(client_id=='1904'){data.cv_lift_cpg=CookiesVx.get(`${voxus_key}_cv_lift_cpg`);} data.pageview=window.location.href.replace("#","");data.data=dateLogglyString;data.action='mediamanager';data.usubidainter=adinter;data.lftst=liftStudy;data.kopidpip=kopid;data.category=CookiesVx.get(voxus_key+"_seg_kaoq");data.sgotasdkaoq=sgotasdkaoq;data.creative=creativekaoq;data.other=isFromOther();data.other=fromOther;data.otherv2=fromOtherv2;data.recent_conv=CookiesVx.get(voxus_key+"_usubida_tracking");data.ga=alihuadsa;data.ds_hit_sent=analyticsAttributionHitsSentOnPage.ds;data.tf_ds_hit_sent=analyticsAttributionHitsSentOnPage.tfDs;data.ga_not_sent_reason=gaNotSentReason;data.new_user_not_reset_reason=noNewUserResetReason;data.ad_placement_domain=CookiesVx.get(voxus_key+"_ad_placement_domain");data.lftst=analyticsAttributionHitsSentOnPage.ga?1:0;data.cookie_id=cookie_id;if(hasCustomization('2753_custom_track')){data.wpp_triggered=wppTriggered;data.appointment_triggered=appointmentTriggered;} const session=getSessionId(measurementId);data.mobile=ismobile;data.creative=creativekaoq;data.dimension=false;data.session=session;data.user_id=getUserId(measurementId);data.sessionChanged=sessionChanged(session);data.sessionReseted=CookiesVx.get(voxus_key+"_session_reseted");if(typeof getActivePaidMedia==='function'){data.actv_paid_media=getActivePaidMedia();} const kopidIp=CookiesVx.get(voxus_key+'_kopid_ip');if(kopidIp){data.tag_version=kopidIp;} if(hasCustomization('analytics_observer')&&observedRequests){data.analytics_requests=observedRequests;} if(hasCustomization('analytics-multi-tid-voxus-hit-observer')){data.rewrite_ip=JSON.stringify(analyticsServersReceivedHitsOnPage);} if(typeof getPageIdentifier==='function'){data.page_identifier=getPageIdentifier();} if(hasCustomization('register_first_page')){data.first_page=CookiesVx.get(voxus_key+"_registered_first_page")!="true";} if(CookiesVx.get(voxus_key+"_dimension")=="true"){data.dimension=true;} if(typeof CookiesVx.get(voxus_key+"_lkaoq")!="undefined"&&CookiesVx.get(voxus_key+"_lkaoq")!=""){data.lkaoq=CookiesVx.get(voxus_key+"_lkaoq");} if(CookiesVx.get(voxus_key+"_lrf")!=""){data.lref=CookiesVx.get(voxus_key+"_lrf");} if(typeof CookiesVx.get(voxus_key+"_cp_ent")!='undefined'){data.campaign_id=CookiesVx.get(voxus_key+"_cp_ent");} var protocol=window.location.protocol.replace(":","");var token='27cf9a30-eb89-41a7-ba82-3280d33fb2cf';var urlLoggly=protocol+"://logs-01.loggly.com/inputs/"+token+"/tag/"+protocol+"/";var httploggly=new XMLHttpRequest();httploggly.open("POST",urlLoggly,true);httploggly.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httploggly.send(JSON.stringify(data));lastDataLoggly=data;var iNew=document.createElement('img');iNew.id='inserted_log_27c';iNew.style="border-style:none;visibility:hidden;position:absolute;z-index:-1;display:none";iNew.width=iNew.height=1;document.body.appendChild(iNew);httploggly.onreadystatechange=function(){if(httploggly.readyState!=4){return;} if(httploggly.status!=200){sdloggly(false);return;} if(hasCustomization('register_first_page')){CookiesVx.set(voxus_key+"_registered_first_page",'true',{domain:window.location.hostname.replace('www',''),expires:addDaysToDate(new Date,1).toGMTString()});} var response=JSON.parse(httploggly.responseText);if(response==null||typeof response.response=="undefined"||response.response!="ok"){sdloggly(false);}}} VxAsyncWrapper.setTimeout(function(){logglyOnloadVoxusDsp=VxAsyncWrapper.setInterval(function(){if(document.body==null){return;} if(logglyloadvoxus){clearInterval(logglyOnloadVoxusDsp);return;} if(document.getElementById('lgvx')!=null){clearInterval(logglyOnloadVoxusDsp);return;} if(__domain__.indexOf('vtexcommercestable.com.br')>-1){clearInterval(logglyOnloadVoxusDsp);return;} sdloggly();clearInterval(logglyOnloadVoxusDsp);},3000);},3000);var inputs,index;inputs=document.getElementsByTagName('input');function sdconv() {sgarqRun=true;var data=new FormData();data.append('client',client_id);data.append('campaign',CookiesVx.get(voxus_key+"_campaign_"));var typeConversion=0;if((kopid==true||kopiduh==true)&&adinter=="true"){typeConversion=1;}else if(kopid==true||kopiduh==true){typeConversion=2;}else if(adinter==true){typeConversion=1;} var xmlhttp=new XMLHttpRequest();CookiesVx.set(voxus_key+"_converted","true",{domain:'.'+__domain__,expires:60*60});CookiesVx.set(voxus_key+"_converted_gl","true",{domain:'.'+__domain__,expires:60*60});CookiesVx.expire(voxus_key+"_adinter_pip");CookiesVx.expire(voxus_key+"_kopid_uh_pip");CookiesVx.expire(voxus_key+"_kopid_pip");var axel=Math.random()+"";var a=axel*10000000000000;var pipscript2=document.createElement('img');pipscript2.src="https://secure.adnxs.com/seg?add=10100757:"+(client_id*12)+"&t=2";pipscript2.frameborder=0;pipscript2.async=true;pipscript2.width=pipscript2.height=1;pipscript2.style='display:none;visibility:hidden';pipscript2.height=0;pipscript2.width=0;pipscript2.hspace="0";pipscript2.vspace="0";pipscript2.marginheight="0";pipscript2.marginwidth="0";pipscript2.frameBorder="0";pipscript2.scrolling="No";var s=document.getElementsByTagName('body')[0].lastChild;s.parentNode.insertBefore(pipscript2,s);var urlTrackerVx="https://api.voxus.tv/track.png?adv_id="+client_id+"&cv=true";var httptrk=new XMLHttpRequest();httptrk.open("GET",urlTrackerVx,true);httptrk.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httptrk.send();CookiesVx.set(voxus_key+"_usubida_tracking",true,{domain:'.'+__domain__,expires:60*60*24*7});} function getConvIdForAdvertiser(){const msIds=getMeasurementIds();if(!msIds||msIds.length===0){return;} return getDatalayerTransactionId(findDataLayer(msIds.at(0)));} function sdinterv() {} function __voxusTrackConversion(){if(CookiesVx.get(voxus_key+"_converted")!="true"&&(kopid=="true"||adinter=="true")){if(converted==true){return;} sgarqRun=true;sgarq();if(CookiesVx.get(voxus_key+"_campaign_")==null){for(var i=0;iitem?.event==="purchase"||item?.[1]==="purchase").then(async(item)=>{const url=new URL(window.location.href);const transactionId=url.searchParams.get('og');if(CookiesVx.get(voxus_key+"_assigned")&&!isFromOther()){const vtexData=await fetchVtexSession();sendToLoggly({type:'vtex_hit',url:window.location.href.replace("#",""),vtex_session:vtexData,transaction_id:transactionId,});}});} if(hasCustomization('custom_conv_id')){const msIds=getMeasurementIds();if(msIds&&msIds.length>0){const dataLayerName=findDataLayer(msIds.at(0));if(dataLayerName){listenDataLayerChangesUntil((item)=>item?.event==="purchase"||item?.[1]==="purchase",1000,dataLayerName).then((item)=>sdloggly(true));}}} if(hasCustomization('track_conv_url')){listenUrlChangesUntil(usubidaPages[0],()=>sdloggly(true));} reloadPixels();} checkEnterprise=function(){function getCustomDimensionRtgAttributionDays(){return client_id==='2753'?1:30;} function getTopFunnelLiftCampaigns(mainCpgId){let ids=[];if(tfAdvId===2797){ids=[27372121,27372348];} ids.push(mainCpgId);return ids;} async function processSecondaryDimension(){if(!hasCustomization('ds_hit')){return;} const isIpa=CookiesVx.get(voxus_key+"_acs")!="true";const response=await getVerifyTrackData(client_id,cookie_id,isIpa);var acsBef=CookiesVx.get(voxus_key+"_acs");CookiesVx.set(voxus_key+"_acs","true",{domain:'.'+__domain__,expires:30*24*60*60});if(!response||!response.data||response.data.length===0){return;} var hasLookalike=false;const secondaryDimensionCampaigns=[];for(var q=0;q(24*30)){continue;} hasLookalike=true;secondaryDimensionCampaigns.push(sdCpgId);}else if(sdCpgId=='11393'){if((diffDate/1000/60/60)>(24*2)){continue;} hasLookalike=true;secondaryDimensionCampaigns.push(sdCpgId);}else{const rtgDays=getCustomDimensionRtgAttributionDays();if((diffDate/1000/60/60)>(24*rtgDays)){continue;} hasLookalike=true;secondaryDimensionCampaigns.push(sdCpgId);}} if(secondaryDimensionCampaigns.length>0){initializeInternalGtag();if(algs!=null&&dsName!=''&&tID!=''){algs('event','page_view',{'send_to':getMeasurementIds(),[dsName]:'voxus_user'});analyticsAttributionHitsSentOnPage.ds=true;}}} async function processTopFunnelSecondaryDimension(){if(!hasCustomization('tf_ds_hit')||(tfAdvId==0||tfAdvId==undefined||tfAdvId==null||tfCpgId==0||tfCpgId==undefined||tfCpgId==null)){return;} const response=await getVerifyTrackData(tfAdvId,cookie_id,false);var acsBef2=CookiesVx.get(voxus_key+"_acs2");CookiesVx.set(voxus_key+"_acs2","true",{domain:'.'+__domain__,expires:30*24*60*60});if(!response||!response.data||response.data.length===0){return;} var hasLookalike=false;const tfSecondaryDimensionCampaigns=[];const tfIds=getTopFunnelLiftCampaigns(0);for(var q=0;q(24*30)){continue;} hasLookalike=true;tfSecondaryDimensionCampaigns.push(kaoqCpgId);}else if(kaoqCpgId=='11393'){if((diffDate/1000/60/60)>(24*2)){continue;} hasLookalike=true;tfSecondaryDimensionCampaigns.push(kaoqCpgId);}else if(tfIds.includes(kaoqCpgId)){if((diffDate/1000/60/60)>(24*2)){continue;} hasLookalike=true;tfSecondaryDimensionCampaigns.push(kaoqCpgId);}else{if((diffDate/1000/60/60)>(24*30)){continue;} hasLookalike=true;tfSecondaryDimensionCampaigns.push(kaoqCpgId);}} if(tfSecondaryDimensionCampaigns.length>0){initializeInternalGtag();if(algs!=null&&tfDsTid!=''&&tfDsName!=''){algs('event','page_view',{'send_to':getMeasurementIds(),[tfDsName]:'voxus_user'});analyticsAttributionHitsSentOnPage.tfDs=true;}}} if(1==1||2==1){processSecondaryDimension();processTopFunnelSecondaryDimension();}} function isUserEligibleForCdAttribution(initialDate,force=false){const cookieName=voxus_key+"_cd_attr_status";const group=CookiesVx.get(cookieName);if(group){return group==='true';} const isEligible=force||shouldResetUserByFeatureActivationDate(initialDate,{duration:20,baseProb:0.05,maxProb:1,forceResetAfter:20});const newGroup=isEligible?"true":"false";const groupAssignmentTTL=7;CookiesVx.set(cookieName,newGroup,{domain:'.'+__domain__,expires:addDaysToDate(new Date(),groupAssignmentTTL)});return isEligible;} const isMobileAttr=ismobile&&attmob;const cdAttrDate='2025-09-01T13:32:54+00:00';const forceCdAttr=hasCustomization('force-cd-attr');const hasCdAttrActive=hasCustomization('cd-attr')||forceCdAttr;const isEligibleCdAttr=hasCdAttrActive&&isUserEligibleForCdAttribution(cdAttrDate,forceCdAttr);if(isMobileAttr||isEligibleCdAttr){async function checkAdvertiserMobileImpression(){const advertiserIds=hasCustomization('multi_adv_same_adv')&&typeof associatedAdvData!=='undefined'?Object.keys(associatedAdvData):[];advertiserIds.push(client_id);if(CookiesVx.get(voxus_key+"_redir")==='true'||isFromOther()){return;} for(const advertiserId of advertiserIds){try{const response=await getVerifyTrackData(advertiserId,cookie_id,false);if(!response||!response.data||response.data.length===0){continue;} const allCampaigns=[];let mostRecent=null;for(const item of response.data){const dateObj=new Date(item.date);if(!mostRecent||dateObj>mostRecent.dateObj){mostRecent={...item,dateObj};} allCampaigns.push(item.campaign);} const effective=new Date(mostRecent.dateTz||mostRecent.date);const diffHours=(Date.now()-effective.getTime())/(1000*60*60);if(diffHours>24){continue;} const oneHourExpiration=addHoursToDate(new Date,1);kopid=true;CookiesVx.set(voxus_key+"_kopid_pip",'norender-ip-apnx',{domain:'.'+__domain__,expires:oneHourExpiration});CookiesVx.set(voxus_key+"_seg_kaoq",allCampaigns.join(','),{domain:'.'+__domain__,expires:oneHourExpiration});const adPlacementDomain=mostRecent.ad_placement_domain&&mostRecent.ad_placement_domain!==''?mostRecent.ad_placement_domain:'';CookiesVx.set(voxus_key+"_ad_placement_domain",adPlacementDomain,{domain:'.'+__domain__,expires:oneHourExpiration});const mostRecentCampaign=mostRecent.campaign;const mostRecentCreative=mostRecent.crtv&&mostRecent.crtv!=='None'?mostRecent.crtv:'';CookiesVx.set(voxus_key+"_kopid_uh_pip",`${mostRecentCreative}-${mostRecentCampaign}-apnx`,{domain:'.'+__domain__,expires:oneHourExpiration});const mostRecentImpression=mostRecent.dateObj;setLastImpressionTimestampCookie(mostRecentImpression.getTime());if(hasCdAttrActive){const expiresDate=addHoursToDate(mostRecentImpression,24);CookiesVx.set(voxus_key+'_kopid_ip','true_'+mostRecentCampaign,{domain:'.'+__domain__,expires:expiresDate});} if(hasCustomization('multi_adv_same_adv')&&associatedAdvData?.[advertiserId]){associatedAdvData[advertiserId].kaoq=true;} break;}catch(error){vxLogger.debug('Error in `checkAdvertiserMobileImpression` for advertiser: ',client_id,error);vxLogger.trace(error.stack);}}} checkAdvertiserMobileImpression();} var sgotasdExists=false;function reloadPixels(){var pixelsApip=[[2,18900516],[3,18900517],[4,18900520],[5,18900521],[6,18900523],[7,18900526],[17,19511481],[8,21307745],[9,21307747],[10,21307767],[11,22348208],[12,22348217],[13,28987544],[14,28987548],[15,28987552],[16,28987553],[17,28987554],[18,28987555],[19,28987556],[20,28987557],[21,37810358],[22,37810359],[23,37810360],[18,38626857],[24,38982160],[25,38982161]];var canRenderPixels=true;if(___vx__runCVL==true){if(typeof CookiesVx.get(voxus_key+"_cvl")!="undefined"){if(CookiesVx.get(voxus_key+"_cvl")==1){canRenderPixels=false;}}} if(canRenderPixels){const mediaMathTestAdvertiserIds=['2321','1421','2653'];if(mediaMathTestAdvertiserIds.includes(client_id)&&typeof addMediaMathPixel==='function'){addMediaMathPixel(client_id);} const stackAdaptAdvertiserToPixelMap=new Map([['1218','XrOxkvdN7Gnbq9fRvXpEOF'],['2776','MHHgGFhx90wTomt4jLYsLL'],['2673','glB7BKWD1wsagVLd1fxh2V'],['2249','xYhXiz6NHllrU2VQIf1QQm'],['1774','wf7nQXdSPkx8AnamLnB63o'],['2423','QK3jiqJh0KLHOuUN6oxYib'],['2383','pO4IxVpweITCRWPYcrJlw9'],['2761','LentFLoceyxd3XhrqxbQla'],['2321','r2hrDs8S17BM6pIyIAnI3e'],['2992','bVlgmRhi13QTZbFjd4W2V9'],['2619','PGuC9wiZondDITElaWsHbW']]);if(stackAdaptAdvertiserToPixelMap.has(client_id)&&typeof addStackAdaptPixelId==='function'){addStackAdaptPixelId(stackAdaptAdvertiserToPixelMap.get(client_id));} const stackAdaptAdvertiserToSegmentedPixelMap=new Map([['1774',{pixelId:'ZXCpAtD7VNsLAdR3hJoWfM',segmentName:'/checkout'}],['2673',{pixelId:'Y3YuZeH9IN8AIm2YYF3IcB',segmentName:'/checkout'}],['1218',{pixelId:'HV8b0Q1iLcNNDkfOz50eLp',segmentName:'/carrinho'}],['2249',{pixelId:'m5ZZdMMSaNs3tJQSTLz8wq',segmentName:'checkout.colombo.com.br'}],['2321',{pixelId:'g0RnrwdgRUdY01d9tXtFWW',segmentName:'/checkout'}],['2761',{pixelId:'GAHXPtdy40svT3MIE6HACj',segmentName:'/checkout'}],['2383',{pixelId:'ISMxhQWbobrUv5stxA9IGc',segmentName:'/checkout'}],['2423',{pixelId:'Jvmqsd8lmuDbgbmCkAJ3Lb',segmentName:'/checkout'}],['2776',{pixelId:'1hQG5kFT7OCrHYYG2USzN4',segmentName:'/checkout'}],['1464',{pixelId:'1P5PFlhv09sro2Md2VBZWO',segmentName:'/checkout'}],['1401',{pixelId:'fh2UyvuexnLeG7WEqK8VbT',segmentName:'/checkout'}],['2775',{pixelId:'nZIJQ8jqhc99L88Dafqgq0',segmentName:'/checkout'}],['386',{pixelId:'mOoN8LEM2GVjFbYCa3ll3B',segmentName:'/checkout'}],['2328',{pixelId:'qMX16SnLx0rPF0yPnhwR8y',segmentName:'/preco'}],['2703',{pixelId:'j2DHQCBWw1gKcWdqI0V8oq',segmentName:'/checkout'}],['1859',{pixelId:'5Ef8dikGyx0oFTSlfffnbg',segmentName:'/checkout'}],['2610',{pixelId:'LQiyg0TbuJLoamVwdpJtBl',segmentName:'checkout'}],['2596',{pixelId:'c2JbMrWvav49xY1inbK3V7',segmentName:'checkout'}],['2163',{pixelId:'3GYtthDmBTkoRBA2HhAxlJ',segmentName:'checkout'}],]);if(stackAdaptAdvertiserToSegmentedPixelMap.has(client_id)&&typeof addStackAdaptPixelIdIfOnSegmentPage=='function'){addStackAdaptPixelIdIfOnSegmentPage(stackAdaptAdvertiserToSegmentedPixelMap.get(client_id))} if(client_id==='2579'){addXandrPixel(40874045);} if(client_id==='2839'&&typeof addMetaPixel==='function'){addMetaPixel('2136470616846984');} for(var i=0;i{return encodeURIComponent(key)+'='+encodeURIComponent(data[key])}).join('&');var urlTrackerVx="https://api.voxus.tv/track.png?"+queryString;var httptrk=new XMLHttpRequest();httptrk.open("GET",urlTrackerVx,true);httptrk.setRequestHeader("Content-Type","application/x-www-form-urlencoded;charset=UTF-8");httptrk.send();}}} targetingOnload=VxAsyncWrapper.setInterval(function(){if(document.body==null){return;} if(document.getElementById('_VOXUS___TARGETING___DATA')!=null){clearInterval(targetingOnload);return;} clearInterval(targetingOnload);var script=document.createElement('iframe');const indexNckFile=hasCustomization('multi_adv_same_adv')?'index_nckv5':'index_nckv4';script.src='https://targeting.voxus.tv/a/'+indexNckFile+'.html?12943a233&'+VOXUS_RTDT_DATA+"&v=5"+`&nckV=${indexNckVersion}`;script.id='_VOXUS___TARGETING___DATA';script.frameborder=0;script.async=true;script.width=script.height=1;script.style='display:none;visibility:hidden';script.onload=function(){var e=this;e.contentWindow.postMessage({type:'voxus_dmp',url:window.location.href,html:document.head.outerHTML+document.body.outerHTML,dataType:'publisher'},"*");};var vxeventMethod=window.addEventListener?"addEventListener":"attachEvent";var vxeventer=window[vxeventMethod];var vxmessageEvent=vxeventMethod=="attachEvent"?"onmessage":"message";vxeventer(vxmessageEvent,function(e){if(typeof e.data!='object'){return;} if(e.data.type=='dataexclude'){if(e.data.exclude=='true'){CookiesVx.set(voxus_key+"_dataexclude","true",{domain:'.'+__domain__,expires:Infinity});}else{CookiesVx.expire(voxus_key+"_dataexclude");} dataExcludeValidated=true;} if(e.data.type=='user'){cookie_id=e.data.user_id;CookiesVx.set(voxus_key+"_id",cookie_id,{domain:'.'+__domain__,expires:60*60});if(typeof checkEnterprise=='function'){checkEnterprise();}} const voxusLastImpressionVariableName='voxus_last_impression_timestamp_'+client_id;if(e.data.type===voxusLastImpressionVariableName&&e.data[voxusLastImpressionVariableName]!=null&&e.data[voxusLastImpressionVariableName]!==""){const previousVoxusLastImpressionTimestamp=CookiesVx.get(voxusLastImpressionVariableName);if(previousVoxusLastImpressionTimestamp!==e.data[voxusLastImpressionVariableName]){setLastImpressionTimestampCookie(e.data[voxusLastImpressionVariableName]);}} if(e.data.type=='voxus_kopid'){handleAdSeenMessage(e);}else if(hasCustomization('multi_adv_same_adv')&&typeof e.data.type!='undefined'&&e.data.type.startsWith("voxus_kopid_")){const tokensLimit=3;const eventTypeTokens=e.data.type.split("_",tokensLimit);if(eventTypeTokens.length===tokensLimit){handleAssociatedAdvertiserEvent(eventTypeTokens,tokensLimit);}} function handleAssociatedAdvertiserEvent(eventTypeTokens,tokensLimit){const associatedAdvertiserId=eventTypeTokens[tokensLimit-1];if(typeof associatedAdvData=='undefined'){return;} const data=associatedAdvData[associatedAdvertiserId];if(data){const response=handleAdSeenMessage(e);if(response.kopid){data.kaoq=response.kopid;}}} function handleAdSeenMessage(e){const response={kopid:false,kopiduh:false,kopidck:false,creativekaoq:null};const cv_lift_ids=e.data.cv_lift_ids;if(Array.isArray(cv_lift_ids)&&cv_lift_ids.length>0){CookiesVx.set(`${voxus_key}_cv_lift_cpg`,cv_lift_ids.join(","),{domain:`.${__domain__}`,expires:60*60*24*30});} if(e.data.voxus_kopid!=null&&e.data.voxus_kopid!=""){if(fromOther==false){CookiesVx.set(voxus_key+"_kopid_pip",e.data.voxus_kopid,{domain:'.'+__domain__,expires:60*60});CookiesVx.set(voxus_key+"_seg_kaoq",e.data.segkaoq,{domain:'.'+__domain__,expires:60*60});kopid=true;response.kopid=true;creativekaoq=e.data.voxus_kopid;response.creativekaoq=e.data.voxus_kopid;}else{kopid=true;response.kopid=true;}} if(e.data.voxus_kopid_tmp!="null"&&e.data.voxus_kopid_tmp!=""&&e.data.voxus_kopid_tmp!=null){let blockOther=false;if(hasCustomization('other_v2')&&!isVoxusLastPaidMedia()){blockOther=true;const timestampCookie=CookiesVx.get('voxus_last_impression_timestamp_'+client_id);if(timestampCookie){const cookieDate=(new Date(timestampCookie*1000)).toISOString();sendToLoggly({type:'expire_v3',pageview:window.location.href,activePaidMedia:getActivePaidMedia(),cookie_id:cookie_id,ads:kopid,hasIgnore:CookiesVx.get(voxus_key+"_ignoreot_full"),timestampCookie:cookieDate,});}} if(!blockOther){CookiesVx.expire(voxus_key+"_ignore");CookiesVx.expire(voxus_key+"_ignoreot_full");} CookiesVx.set(voxus_key+"_kopid_pip",e.data.voxus_kopid_tmp,{domain:'.'+__domain__,expires:60*60});CookiesVx.set(voxus_key+"_seg_kaoq",e.data.segkaoq,{domain:'.'+__domain__,expires:60*60});kopid=true;response.kopid=true;if(alihuadsa==false){sgarq();} creativekaoq=e.data.voxus_kopid_tmp;document.getElementById('_VOXUS___TARGETING___DATA').contentWindow.postMessage({type:'remove_tmp_cookie'},"*");} if(e.data.voxus_kopid_uh!=null&&e.data.voxus_kopid_uh!=""){CookiesVx.set(voxus_key+"_kopid_uh_pip",e.data.voxus_kopid_uh,{domain:'.'+__domain__,expires:60*60});CookiesVx.set(voxus_key+"_kopid_pip",e.data.voxus_kopid_uh,{domain:'.'+__domain__,expires:60*60});kopid=true;response.kopid=true;creativekaoq=e.data.voxus_kopid_uh;response.creativekaoq=e.data.voxus_kopid_uh;kopiduh=true;response.kopiduh=true;} if(e.data.voxus_kopidck=="1"){CookiesVx.set(voxus_key+"_kopidck_pip","true",{domain:'.'+__domain__,expires:60*60});response.kopidck=true;} if(e.data.cp_ent!="null"&&e.data.cp_ent!=""&&e.data.cp_ent!=null&&adinter!=true){CookiesVx.set(voxus_key+"_cp_ent",e.data.cp_ent,{domain:'.'+__domain__,expires:60*60});if(alihuadsa==false){sgarq();}} if(e.data.ad_placement_domain!="null"&&e.data.ad_placement_domain!=""&&e.data.ad_placement_domain!=null){CookiesVx.set(voxus_key+"_ad_placement_domain",e.data.ad_placement_domain,{domain:'.'+__domain__,expires:60*60});} return response;}},false);var s=document.getElementsByTagName('body')[0].lastChild;s.parentNode.insertBefore(script,s);},1000);if(typeof intervalDataExcludeValidated=='undefined'){intervalDataExcludeValidated=VxAsyncWrapper.setInterval(function(){if(dataExcludeValidated==false)return;dataExcludeValidated=true;clearInterval(intervalDataExcludeValidated);if(typeof CookiesVx.get(voxus_key+"_dataexclude")=="undefined"){__voxMainProc();}},100);}}catch(error){if(VOXUS_DEBUG){console.trace(error);}}