Avatar of Rick Mellon
Rick Mellon
Flag for United States of America asked on

Looking for help adding a timestamp custom dimension to Google Analytics.

I have a several microsites in need of customized Google Analytics. Specifically, I want to add a timestamp custom dimension to page views and events.

I've managed to add a timestamp javascript to one of the sites. It appears on the GA dashboard but isn't collecting data. I'm looking for someone to help fix this, and then possibly discuss using a Google API to create a third-party dashboard for clients who can't access GA because Gmail is blocked by their firewall.  

GoogleAnalyticsJavaScript

Avatar of undefined
Last Comment
David H.H.Lee

8/22/2022 - Mon
David H.H.Lee

I've managed to add a timestamp javascript to one of the sites. It appears on the GA dashboard but isn't collecting data.  
Since it already viewable in GA dashboard, it should working fine. Can you share with us what you mean by "isn't collecting data"?

You can add the GA custom dimension for timestamp via javascript or Google Tag Manager(GTM).
If the connecting isn’t working, make sure you have disable any kind of adblockers like AdBlock or Ghostery before check again your GA result.

Cross-check the steps if anything misses out in your configuration:
https://sandervolbeda.com/add-timestamp-to-google-analytics/
Rick Mellon

ASKER
Thank you, David.

When I view the standard Page View report, it shows activity. But when I select the Timestamp custom dimension, all values in the page view table are cleared and replace with a single row of zeroes.

I had followed the video which was at the bottom of the article you shared, but I had not completed the steps related to this: 
  1. Check: Enable overriding settings in this tag

So I checked that box, entered the Universal Analytics tracking ID, and hope that fixes the issue.

Unfortunately, the Tag Manager Preview says that it detects a legacy js tag for the site I'm monitoring. I'm not sure why, since it seems to be current, but I can't get beyond that message in Preview to see anything else. I'll check Google Analytics tomorrow to see if data is now being displayed with Timestamp.

--Rick 
David H.H.Lee

Unfortunately, the Tag Manager Preview says that it detects a legacy js tag for the site I'm monitoring. I'm not sure why, since it seems to be current, but I can't get beyond that message in Preview to see anything else. I'll check Google Analytics tomorrow to see if data is now being displayed with Timestamp. 
Well noted. Awaiting your good news and please share with us if you need any further assistance for this topic.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
Rick Mellon

ASKER
David, I'm making some progress by starting fresh with another microsite. A couple of quick questions.

Would you verify that the Google Analytics tracking ID in step 3.3 from https://sandervolbeda.com/add-timestamp-to-google-analytics/ below should be the UA ID?

3.2 Check: Enable overriding settings in this tag
3.3 Add the Google Analytics tracking ID manually

Also, I'd like to verify that only the ID should be entered. If I click on the camera icon, it brings up a list of Variables that can be added.

The reason I ask is, there is no "Variables" tab in the GA Tag Assistant for Universal Analytics, just "Hits Sent" "Data Layer" and "Errors".

"Variables" does appear if the GTM ID is selected, and it shows the Timestamp variable – but "Return Type" and "Value" are both "undefined" – I assume because I've entered the UA ID in step 3.3 above.


ASKER CERTIFIED SOLUTION
David H.H.Lee

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question