Hello,

I am trying to install our tracking code for google analytics on our official company forums.

I inserted this code into the bottom of "footer.tpl" above the </body> tag:
Code
<?php include_once("http://forums.sma-america.com/analyticstracking.php"); ?>

I then created a PHP file called "analytics.php" and placed it into the root directory. The analytics.php file has this code in it:
Code
<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-XXXXXX-X");
pageTracker._trackPageview();
} catch(err) {}</script>

After waiting 48 hours, it still has no data from my traffic stats.

Is there something I am doing wrong? Do I even need the analytics.php file or can I just insert my GA code directly into the footer.tpl file? I tried inserting it into the footer.tpl file already, but also got no data on traffic...side note, I didnt wait 24 hours either.

Can someone tell me definitivley how to make this work?

Thank you very much!

BTW, I tried searching the forums first and found no relevant threads already.