Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #678409

    Hello!

    I would like to add an event tracker on each of the different tab of my product page (see below) in order to see what is the most relevant and if people do click on each of them or just in one or two.

    Would you know how to do this?

    Thank you so much for your help,

    Vincent

    #678481

    Hey,

    Refer to:
    https://kriesi.at/support/topic/please-clear-this-up-for-em-ga-tracking-2/#post-348525

    The tracking part would be something like this:

    $('.tab_titles .tab_counter_0').on('click', function() {
        ga('send', 'event', 'button', 'click', 'button-1');
    });
    $('.tab_titles .tab_counter_1').on('click', function() {
        ga('send', 'event', 'button', 'click', 'button-1');
    });
    $('.tab_titles .tab_counter_2').on('click', function() {
        ga('send', 'event', 'button', 'click', 'button-1');
    });
    $('.tab_titles .tab_counter_3').on('click', function() {
        ga('send', 'event', 'button', 'click', 'button-1');
    });
    $('.tab_titles .tab_counter_4').on('click', function() {
        ga('send', 'event', 'button', 'click', 'button-1');
    });
    

    Best regards,
    Josue

    #678496

    Thank you so much Josue! I wish I knew this before!

    Could you tell me what this line

    $('.tab_titles .tab_counter_0')

    would be for an accordeon?

    Many thanks again!

    Vincent

    #678506

    Hi,

    Try this:

    $('[data-fake-id="#toggle-id-25"]')
    

    25 would be the numeric value of the toggle.

    Best regards,
    Josue

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.