• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Where would be the best place to insert statistics logging code?

I understand that there is Google Analytics support built in, which will place the GA script in the <head> element.

But if you were to use another statistics tool, like bbclone for example, where would be the best place to insert these (PHP) code? If at all possible to insert custom PHP code into the template. Ideally you would want to do it a point where you have the topic/thread information available, so you can track useful statistics.

Any suggestion would be much appreciated.
statistic codes usually aren't php.

Insert your code into the footer template
I thought the footer template is the logical choice too, but just want to make sure and get different opinions or suggestions.

bbclone (http://www.bbclone.de) is PHP based, so it needs to be inserted into a PHP script somewhere. I don't know whether PHP snippets can be inserted into the templates, and if so, I don't have any information on the correct syntax to use.

Is there a central location where template customisation is documented?


Well-known member
Hmmmm I looked at your link.
Your code should be javascript. and If I'm correct (which I'm not sure) the admin panel is php but the actual code to insert is probably javascipt ;)

Anyone familiar enough with the back-end to give exact how-to for the footer template? (Sorry I didn't get to play enough with xenforo yet :D)