Skip to content

Commit

Permalink
adding a google analytics module
Browse files Browse the repository at this point in the history
  • Loading branch information
dogmatic69 committed Jan 22, 2010
1 parent 613432a commit f4e7065
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions views/elements/modules/google_analytics.ctp
@@ -0,0 +1,9 @@
<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("<?php echo $config['code']; ?>");
pageTracker._trackPageview();
} catch(err) {}</script>

0 comments on commit f4e7065

Please sign in to comment.