1function getUTMParams(){const urlParams=new URLSearchParams(window.location.search);const utmParams={utm_source:urlParams.get('utm_source')||'',utm_medium:urlParams.get('utm_medium')||'',utm_campaign:urlParams.get('utm_campaign')||'',utm_content:urlParams.get('utm_content')||'',utm_term:urlParams.get('utm_term')||''};return utmParams} 2function trackPaidMedia(){const utmParams=getUTMParams();if(utmParams.utm_source&&utmParams.utm_medium){const paidMediaList=JSON.parse(localStorage.getItem('historico_de_midia_paga'))||[];const newEntry={utm_source:utmParams.utm_source,utm_medium:utmParams.utm_medium,utm_campaign:utmParams.utm_campaign,utm_content:utmParams.utm_content,date:new Date().toLocaleString('pt-BR',{timeZone:'America/Sao_Paulo'})};paidMediaList.push(newEntry);localStorage.setItem('historico_de_midia_paga',JSON.stringify(paidMediaList))}} 3function formatPaidMediaList(paidMediaList){const parsedList=JSON.parse(paidMediaList)||[];return parsedList.map(entry=>`Fonte: ${entry.utm_source}, Campanha: ${entry.utm_campaign}, Data: ${entry.date}`).join('\n')} 4function populatePaidMediaField(){const paidMediaField=document.getElementById('form-field-historico_de_midia_paga');if(paidMediaField){const paidMediaList=localStorage.getItem('historico_de_midia_paga');paidMediaField.value=paidMediaList?formatPaidMediaList(paidMediaList):''}} 5trackPaidMedia();document.addEventListener('DOMContentLoaded',populatePaidMediaField)
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.