3.6K members online now
Learn how to set up goals and Ecommerce tracking, verify accuracy of attribution traffic sources, and discuss funnel visualization, Multi-Channel Funnels, the Goal Flow Report, and Enhanced Ecommerce
 
Guide Me
star_border
Reply

GA event tracking issue

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi i have recently started a role where i need to properly tag all of the banners on a website so we can track the clicks in the analytics reports every month.

 

I noticed that the tracking already in place on the homepage looks a little strange to me like the event tracking is backwards.

 

onClick="_gaq.push(['_trackEvent', 'DEFORMERS_HP', 'Homepage',, 0, false]);"> 

 

The above works as i can see it in analytics. 

However from reading documentation i believe it should really look like the below as the categories and labels are in the wrong places and their is no action tag.

 

onClick="ga('send', 'event', 'Homepage Desktop', 'BannerClick', 'DEFORMERS_HP');">

 

 

Universal tagging is in the code so i am trying to change it to the second option but it just does not work.

 

Any ideas?

 

Thanks

Andrew

1 Expert replyverified_user

GA event tracking issue

A T
Participant ✭ ✭ ✭
# 2
A T
Participant ✭ ✭ ✭

GA event tracking issue

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭

Hi, i have looked at this but iv'e no idea what i'm supposed to be checking in that i find it really strange that it works the way it does but if i add an action even it stops working straight away. 

GA event tracking issue

Top Contributor
# 4
Top Contributor

Hi,

 

The first code snippet is for the outdated classic analytics, in order to use the second syntax, you need to update your tracking code to Universal Analytics. https://support.google.com/analytics/answer/1008080?hl=en

 

Hope this helps, let me know if you have questions.


Arnold Majlath, Google Analytics Top Contributor
Was my response helpful? If yes, please accept it as solution.
Circle Me On Google+ | Visit me @ Redfly Digital

GA event tracking issue

Visitor ✭ ✭ ✭
# 5
Visitor ✭ ✭ ✭

Hi Arnold,

 

The site uses Universal analytics, i have checked this in the page source and GA. The event code was setup when they were using the classic one and they just reused the same code the whole time. If i try change this to universal code it will not work.

 

onClick="_gaq.push(['_trackEvent', 'DEFORMERS_HP', 'Homepage',, 0, false]);"> 

 

Above is what currently works but they've no action and i want to reverse the label and category.

 

I added the below but it just does not track.

 

onClick="ga('send', 'event', 'Homepage Desktop', 'BannerClick', 'DEFORMERS_HP');">

 

GA event tracking issue

A T
Participant ✭ ✭ ✭
# 6
A T
Participant ✭ ✭ ✭

plz give the page url? let me see.

GA event tracking issue

Visitor ✭ ✭ ✭
# 7
Visitor ✭ ✭ ✭

gamestopdotie

Marked as Best Answer.
Solution
Accepted by topic author Gamestop
April 2017

GA event tracking issue

Top Contributor
# 8
Top Contributor

Hi,

 

I just checked, the tracking tag in your GTM container is Classic Analytics, not Universal. Every Google Analytics property has been automatically updated to Universal Analytics. You need to change your tracking tag to universal in GTM and set up event tracking through GTM. Please check the articles below for more details:

https://support.google.com/analytics/answer/6164470?hl=en

https://www.optimizesmart.com/event-tracking-in-google-tag-manager-v2-complete-guide/

 

Let me know if you have more questions.


Arnold Majlath, Google Analytics Top Contributor
Was my response helpful? If yes, please accept it as solution.
Circle Me On Google+ | Visit me @ Redfly Digital