Created
May 3, 2014 20:36
-
-
Save bhowe/6206fa704a906a56f1d3 to your computer and use it in GitHub Desktop.
trigger google analytics event in onclick
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<button class="download-pdf" onclick="document.location.href='doc.pdf';_gaq.push(['_trackEvent', 'PDFs', 'Download', 'Doc Name']);"> Doc Name </button> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment