javascript - <script src="//code.jquery.com/jquery-1.11.1.min.js"></script> Breaks my Site, but I need for Event Tracking -


i need jquery event tracking plugins. work following:

<script src="//code.jquery.com/jquery-1.11.1.min.js"></script> 

&

$('.home .et_pb_more_button').on('click',function() { ga('send', 'event', 'button', 'click', 'case study'); }); 

problem...the jquery code breaks functionality of website. how can track events in google analytics, not break jquery functionality?

the site directiveconsulting.com

wordpress loads in jquery automatically admin side of things among other things.

try using jquery in noconflict mode or calling function using jquery instead of $

jquery('.home .et_pb_more_button').on('click',function() {     ga('send', 'event', 'button', 'click', 'case study'); }); 

read here noconflict: documentation


Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

[C++][SFML 2.2] Strange Performance Issues - Moving Mouse Lowers CPU Usage -

ios - Possible to get UIButton sizeThatFits to work? -