Where does the Universal Analytics tracking code go?
ChancyRat
Registered Users Posts: 2,141 Major grins
Where do I put this new, html-y, long, new-format looking code?
GA gave me a message that my old Tracking ID would be replaced with a new one once the transition to Universal Analytics was complete. However that ID no. is identical. So the replacement is supposed to be the code below.
Please let me know what to do and where.
GA gave me a message that my old Tracking ID would be replaced with a new one once the transition to Universal Analytics was complete. However that ID no. is identical. So the replacement is supposed to be the code below.
Please let me know what to do and where.
Website trackingThis is the Universal Analytics tracking code for this property. It’s different from the classic Google Analytics tracking code. To get all the benefits of Universal Analytics for this property, copy and paste this code into every webpage you want to track.
<script> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-123456780', 'joinrats.com'); ga('send', 'pageview'); </script>
0
Comments
You do not need to enter the entire script on SmugMug. You will want to login to your site, click on ACCOUNT SETTINGS > STATS > GOOGLE ANALYTICS and enter your UA code, found in the script above. It is UA-123456780
If you need anything else, please let us know by going to help.smugmug.com and clicking the "Email Us" link
John
SmugMug Support Hero
SmugMug Support Hero
Because I had added old java to the header in Legacy, that 'broke' stats. Would adding this code anywhere, cause the same problem?
I honestly have no idea how you converting your analytics to universal will behave since we still use the ga.js tracking code (not the universal anayltics.js). Is your UA-code the same?
Yes, it's the same code.
GA said everyone will be required to upgrade to Universal Analytics at some point. This is what I see.
The link for info:
https://developers.google.com/analytics/devguides/collection/upgrade/?hl=en_US
Down in that page is another link about the differences in the javascript.
Could Smugmug please take a look at this page:
https://developers.google.com/analytics/devguides/collection/upgrade/reference/gajs-analyticsjs
and since more and more people may just upgrade automatically, because that's the message they see in GA, tell us what will happen, or what the plan is for shifting SM to UA? And maybe post a Caution all over the place about what not to do?
Thanks.
500 hits today in GA, either shortly before, during, or after the transition to UA.
I will see what happens tomorrow/over time as a comparison.