Google Analytics Event Code

Home Forums All Other Themes Google Analytics Event Code

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #58434
    • Topics: 4
    • Replies: 2
    • Total: 6
    Member since: November 12, 2016

    I am using the Cut N Style Pro theme.
    Trying to setup analytics to track the number of times the Book Appointment button in the header is clicked.

    The proper code for my event should be
    a href=”” onClick=”ga(‘send’, ‘event’, ‘Schedule’, ’Click’, ‘Book Appointment’);”>Book Appointment</a

    When I paste the code into the Header Top Info box and click save it deletes analytics code
    onClick=”ga(‘send’, ‘event’, ‘Schedule’, ’Click’, ‘Book Appointment’)
    And only saves:
    a href=”″>Book Appointment</a

    I’ve successfully installed the similar code on other sites without this issue.
    I’m incredibly confused and wondering if there is anything in the theme overwriting analytics.


    Sonal S SinhaSonal S Sinha
    • Topics: 0
    • Replies: 30739
    • Total: 30739
    Member since: August 16, 2013

    Hi Krystin,

    HTML code won’t work in the header top info box. You have to go to header.php and change the anchor code from there for Book Appointment button.


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