Google Analytics Event Tracking Real-Time Buggy

After much too much time figuring out how to implement event tracking on Google Analytics Universal, I think that perhaps I’ve come to something of a conclusion— its “beta” and buggy.

The code that I used to implement it on a link was as follows:

<a href="#" onclick="ga('send', 'event', 'button', 'click', 'nav buttons', 4);"> Link Text </a>

The first issue, was understanding how the code needed to be written as compared to the syntax for event tracking in Google Analytics classic.  I must admit I’m not a javascript guru, so I rely on documentation. The code above hopefully will save someone some time.

The second thing was that once implemented, it doesn’t work consistently across all browsers. At least I couldn’t get it to work, until I found a post that suggested that I install Google Analytics Debugger. As soon as I installed it, the event tracking in real-time worked across Firefox, Safari, and Chrome, (where before that, the tracking was only working in Firefox.) When I say it’s working across all browsers, I don’t mean consistently.  It works if I try really hard to make it work… patiently waiting for the browser to be fully active, checking the real-time overview to make sure it sees me, and then test the event.

I would say it was just me or my computer, but this inconsistency problem was happening with my students, where some students had it working across browsers, and others only one browser.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.