[m-rev.] [PATCH] Replace the Uni's Google Analytics tracking reference.
Paul Bone
paul at bone.id.au
Thu Mar 28 20:47:52 AEDT 2013
Replace the University's Google Analytics tracking reference with one that
we (I) can access the data for.
include/template.inc:
As above.
---
include/template.inc | 24 +++++++++++-------------
1 file changed, 11 insertions(+), 13 deletions(-)
diff --git a/include/template.inc b/include/template.inc
index 6374979..bea9618 100644
--- a/include/template.inc
+++ b/include/template.inc
@@ -34,23 +34,21 @@
<?php
/*
- * This allows the university to track the popularity of our website via Google
+ * This allows us to track the popularity of our website via Google
* Analytics.
*/
?>
<script type="text/javascript">
- var gaJsHost = (("https:" == document.location.protocol) ?
- "https://ssl." : "http://www.");
- document.write(unescape("%3Cscript src='" + gaJsHost +
- "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
-</script>
-<script type="text/javascript">
- try {
- var pageTracker = _gat._getTracker("UA-2808341-16");
- pageTracker._setDomainName(".csse.unimelb.edu.au");
- pageTracker._trackPageview();
- } catch(err) {
- }
+
+ var _gaq = _gaq || [];
+ _gaq.push(['_setAccount', 'UA-39671467-1']);
+ _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>
</BODY>
--
1.8.1.3
More information about the reviews
mailing list