The Serendipity Handbook

You can now read the (german) handbook here: PDF - https://github.com/s9y/Book (LaTeX source).

Forum-Information

Before posting about errors, make sure that the answer cannot already be found in our FAQ or by searching this forum!
Posting is restricted to registered users (registering is free and simple!) due to recent spam attacks. When having trouble with this board, contact garvin(-at)s9y(-dot)org.

Board index General discussions Where do I put statcounter code?

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
accampbell
Regular
 
Posts: 95
Joined: Fri Jun 09, 2006 8:59 pm
Location: London, UK

Postby accampbell » Wed Feb 09, 2011 11:04 am

I found a post here saying statcounter code should go in templates/bulletproof/index.tpl. I don't understand the syntax of this file very well. Whre should the code go - at the end?
Anthony Campbell

User avatar
Timbalu
Regular
 
Posts: 2567
Joined: Sun May 02, 2004 3:04 pm

Postby Timbalu » Wed Feb 09, 2011 11:18 am

Hi Anthony

Yes, the index is ok for that.
But which template do you use? Bulletproof? Take the index of you template.
Somewhere in the footer section would be a choice, or with a nugget inside of the sidebar.

Ian

User avatar
kleinerChemiker
Regular
 
Posts: 720
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria

Postby kleinerChemiker » Wed Feb 09, 2011 12:08 pm

I think the Bulletproof theme has an option for counters in the setup.

accampbell
Regular
 
Posts: 95
Joined: Fri Jun 09, 2006 8:59 pm
Location: London, UK

Postby accampbell » Wed Feb 09, 2011 4:15 pm

Thanks to both for replies. In the end I put the code at the bottom of templates/default/index.tpl and that is working.
Anthony Campbell

User avatar
yellowled
Regular
 
Posts: 4885
Joined: Fri Jan 13, 2006 12:46 pm
Location: Eutin, Germany

Postby yellowled » Wed Feb 09, 2011 5:08 pm

accampbell wrote:Whre should the code go - at the end?

In fact, it depends a little on the exact statcounter code, but in most of the case, you should be fine using the theme option recommended here.

The huge advantage of using the theme option is that it is safe in case of an update. Code in your index.tpl will be overwritten by the next update to S9y and/or BP, code inserted using the theme option box will still work. Of course, this does not apply if you're working with a copy of BP in a seperate directory.

YL



Return to General discussions

Who is online

Users browsing this forum: No registered users and 3 guests