Support » Plugin: WP Google Analytics Events » Click tracking not working

  • Resolved gaiusjaugustus


    Hi, I’ve added click tracking to my site, and checked to see if it was working. I’ve had no issues with the plugin.

    But today, I added a new tracker, and now the click tracking doesn’t appear to be working for any of my buttons.

    Double checked the classes, and everything matches fine. Not sure how else to troubleshoot.

Viewing 12 replies - 1 through 12 (of 12 total)
  • Looking at my analytics, it looked like tracking stopped coming through February 15th, if that helps.

    Plugin Author yuvalo


    Hi @gaiusjaugustus,

    Our plugin doesn’t support multiple trackers at the moment. It will just use the default one when sending out events.
    It shouldn’t stop the tracking altogether though.

    How did you add the tracking code?


    I must not be expressing myself right. Let me try again.

    On the “Click Tracking” page, I added a new Element. I went to track that element on Google Analytics to be sure it was working, and noticed that no events were being tracked from GA Events. Everything was working until Feb 15th, when all elements stopped being tracked.

    Does that make more sense?

    Plugin Author yuvalo


    Oh, got it, sorry.

    Can you send me a link to the page? May be able to tell what is going on there.


    Tracking isn’t working for any buttons on any pages.

    Including, but not limited to: (all buttons have tracking elements) (Learn How button) (Top 3 buttons have tracking elements)

    Thanks. Fingers crossed it’s something simple.

    Plugin Author yuvalo


    Hi @gaiusjaugustus,

    I can see that you are using Google Tag Manager on the website but set the plugin to work with the Universal Tracking code.
    Try giving this guide a try and let me know if it works:


    Set it up with Google Tag Manager.

    Unfortunately, events are still not tracking for any tracking elements.

    Plugin Author yuvalo


    Have you made other changes along the way? I’m seeing a different problem now that is not related to our plugin but breaking our plugin.

    There is a javascript error that prevents our snippet from runnning:
    AnimOnScroll.js:12 Uncaught TypeError: Cannot read property ‘id’ of null
    at AnimOnScroll._init (AnimOnScroll.js:12)
    at new AnimOnScroll (AnimOnScroll.js:11)
    at main.js:1

    Can you please take a look?



    The only change I’ve made was temporarily deactivating my CloudFlare caching, which has been turned back on.


    Plugin Author yuvalo


    Hi @gaiusjaugustus

    Things are looking better now, but I have found another issue –
    Let me start off, that you did set things up correctly, but we need you to make a slight adjustment.

    In the page, you set the element name to point to a div, which is usually fine, but in this specific case, has a link under it.
    When someone clicks the button, the page navigates before the event finishes firing.
    We do have a way to handle such cases when the element you want to track is a link. In those cases, we add a short delay as recommended by Google Analytics.

    To solve this issue you can do one of two things:
    1. Change the element name to a class or an id that the button link has – like kt-btn-0-action
    2. Enable advanced mode, then use the element name – “.CTALearnHow a”, then set the type to advanced. (just copy everything between the quotes, without them)


    I tried this with 2 different links, and no luck:

    1) (Learn How link Above the Fold)
    Element: .CTALearnHow div a
    Type: Advanced

    2) (All Infographics button)
    Element: see-all-infographics
    Type: class

    Then tested them through Google Analytics. Still not showing these events. :\

    I disabled CloudFlare to see if that would fix it for me, but no luck.

    Worked around my settings a bit and fixed buttons as suggested above.

    Was able to fix this issue.

    Turned off Tag Manager options and “Don’t add the GA tracking code” option.

    Seems to be working now. Thanks to everyone for the help in getting me back on track!

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Click tracking not working’ is closed to new replies.