Created
January 16, 2012 21:59
-
-
Save scottwb/1623245 to your computer and use it in GitHub Desktop.
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
<script type="text/javascript"> | |
var _gaq = _gaq || []; | |
_gaq.push(['_setAccount', 'UA-XXXXXXXX-X']); | |
+ _gaq.push(['_setCampSourceKey', 'utm_source']); | |
+ _gaq.push(['_setCampMediumKey', 'utm_medium']); | |
+ _gaq.push(['_setCampContentKey', 'utm_content']); | |
+ _gaq.push(['_setCampTermKey', 'utm_keyword']); | |
+ _gaq.push(['_setCampNameKey', 'utm_campaign']); | |
_gaq.push(['_trackPageview']); | |
(function() { | |
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; | |
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; | |
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); | |
})(); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is not needed. These are the default values. The _setCamp* functions should be used only if you want to change the default values.