David Vallejo - Web Analyst

sameSite Automated Fix and status reporting tool

It has been a hard week with all these vendors announcing the Four Hoursemen of the Cookies Apocalypse arrival.There're a lot of changes coming when we talk about cookies ( 1st, 3rd party ), ITP, GDPR, CCPA,etc . I understand it may be a terrible headache for anyone but we need to keep some calm. Last update has came from Google Chrome, which was expected to start blocking the cookies not containing the sameSite attribute on 4th February. Luckily…


The Definitive Approach for preventing duplicate transactions on Google Analytics - Using a Universal CustomTask

It's been a long time since I wrote my post about how to prevent duplicate transactions on Google Analytics. At that point, the customTask wasn't a thing on the Google Analytics JS library, and the approach consisted of writing a cookie on each transaction and then work with some blocking triggers. It's a working solution for sure, but based on all the feedback I had over the years, it was not easy to understand for people. Things got worse even…


Test API . Unit testing for Google Tag Manager Custom Templates

Google Tag Manager team has just added, in a stealth mode, a new Test API for the Custom Templates. This Test API will allow us to define some Unit Tests in order to be able to automate the testing of our template before publishing them. You will find a new tab within the templates editor named "test" where you will be able to run some code before the tests start, and then add a set of unit test to run each time you want to test your library. For…


UDO Debugger - Easiest way to work and QA Tealium implementations

Some years ago, I published my "Tealium Debugger" extension for Chrome which after a nice email my Inbox got, ended being named "UDO Debugger" ( no hard feelings at all ). You may click no the next CTA if you want to install the extension in your browser =) That version published circa Apr 2017, was just showing up the current app state on the page loads, the current account, profile, and environment details. There was no support for anything else.…


Google Tag Manager Custom Template to grab the current Root domain Name

It happened to me a lot of times that while working with cookies that for whatever the reason I didn't remembered to add the domain name to the settings, or that I was not able to properly define the root domain. If you ever have had the need to set a cookie to the main root domain for your current domain, to make a cookie available for all the place, that depending on your current domain it may not be just enough to split the current hostname, because…


#proTip - Proactively Cookies Auditing with Google Tag Manager and Google Analytics

Since GDPR was announced and more even with the rise of Safari's ITP and the other upcoming protection feature by the other major browsers, the concers about users privacy was grown which is really nice. But despite browsers taking some actions to prevent the abuses, it's difficult to follow up the current cookies being used in our sites because we may end finding new ones that has been added by the developers, or some new pixel added by someone…


Setting GA Cookies Server Side with PHP - ITP Workaround

Yeah, I know, this has been done before by others, but since I had this piece of code around, I decided to publish it. It's not going to be usual, method since we'll be relying on sending a duplicate hit to our tracking subdomain. That way we'll be able to have our stuff tracked server-side in a secondary dimension while those hits will take care of setting the cookie expiring time on the main. isn't it cool? What we'll need A subdomain for our domain,…


#tip - Grabbing current dataLayer variable name within GTM

This is going to be a quick #tip post. and it's coming from a post on Measure Slack. Let's learn how to grab the current dataLayer variable name within GTM. We'll need to create a variable with the following code: function() { return Object.values(window.google_tag_manager).find(function(e) { if (e.dataLayer) return true; }).dataLayer.name; } Now our variable should hold the dataLayer name :)


Send APP+WEB Hits to any remote endpoint

Google released APP+WEB Properties some weeks ago now, and one of the most missed features looking back to Universal Analytics, is the chance to work with a customTask ( Hi Simo!!! ). In this post I'll cover how to send a copy of the hits to anywhere we want, in case we want to hold a copy of them, or processing them in some other place (like snowplow) First, we need to take in mind that APP+WEB hits, may contain +1 hits into their payload, therefore…


Release: Client-Side dataLayer validation Library

If you're a web analyst, you SHOULD be worried about data quality, we want to have data, but we need this data to be correct, there's no point of having tons of corrupted data that we won't be able to sue and for this we need to monitor our implementations regularly to be sure our data is always being reported properly. Since We all are web analyst I'm pretty sure we are relying a flawless dataLayer ( are we? :) ). But I'm sure that at least once…