Skip to content

Instantly share code, notes, and snippets.

@r-sal
Created March 7, 2013 21:21
Show Gist options
  • Save r-sal/5111900 to your computer and use it in GitHub Desktop.
Save r-sal/5111900 to your computer and use it in GitHub Desktop.
// Add in Google Analytics tracking
var track = function(category, name, value) {
if (window._gaq) {
window._gaq.push(["_trackEvent", category, name, value]);
}
};
track("Source", "Visit", this.href);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment