The best way to do this is to use Raw Header feature of CS.
Just go to Control Panel/Settings/Site Name & Description/Raw Header and copy/paste the code Google gives you and save it. This code will be added to all of your pages.
Keyvan NayyeriWaegis Anti-Spam Filter - Stay Away from Spams on Your Community Server Sites
<markvw> wrote in message news:539020@communityserver.org...I am attempting to install Google Analytics on the Community Server portion of our site, but I am unable to locate where the FooterTemplate is located. Can anyone point me in the right direction? http://communityserver.org/forums/thread/539020.aspx
I would NOT modify pages, skins, etc. for this.
Login as an admin. Go to the Control Panel. Click the "Administration" link in the Control Panel. On the left side bar navigation click "Settings". From the menus that show up when the Settings menu expands, click "Site Name & Description". You will see a "Raw Header" field on the form. Place your Google Analytics code there.
This is how we do it on communityserver.org.
haathi featuring a blog..
Hi,
Inserting the google analytics code into raw header doesnt work on my site, google says they arent receiving data.
Any other ideas?
I noticed that google says it has to be right before the </body> tag and CS raw header does it like this:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript"></script><script type="text/javascript">_uacct = "xxxxxxxxxxxx";urchinTracker();</script><title> SiteName.com</title></head> <body>
i removed my uid and replaced with xxx
I am not sure why Telligent recommends adding any analytics script to the header. This can slow down the load of your site if it is at the top. If it was placed at the bottom of your page then at least your whole page will load faster and if there are any issues with google analytics speed then just the footer will load slow.
I always put tracking code at the bottom and I think it would be a great idea for CS2008 to make it easy to add google analytics and any other tracking code to the footer of the pages.
Great suggestion, Tuitionu. I will vote for this improvement too!
I use several tracking codes, and I agree that best practice will be to put the code at the bottom of the page.
Hope Telligent agrees...
Henrik Dahl www.portugalnyt.dk - A Community Server 2007 site about Portugal.
FYI, you can use the site's "Copyright notice" setting for your analytics script. As it stands, since that's only a text box (not a text area), you also have to change the script so that it's on one physical line along with any copyright text. If you are using more extended code, just put it in another file, save it in a web accessible place, and reference this file in the script tag's src attribute.
Also, there's a drawback to placing the code in the header in addition to the performance hit at an undesirable time in the page load process: the script gets parsed & run before the title tag is parsed (in CS2007.1), resulting in empty GA "Content by Title" results - all page names are reported as "(not set)".
There is a content placeholder after the form end tag and just before the body end tag with id="outsidetheform" that appears not to be used anywhere; getting that or something like it hooked up & exposed through settings somewhere would seem appropriate for this and other uses.
Thanks for clarifying the issue regarding Google Analytics and the empty "Content by title" results. I had noticed this problem too.
It is also a nice trick to use the "Copyright notice" for scripts - however I still think that Telligent should implement a field for scripts placed just above the </body> tag as advised by all analytics systems.
I totally agree that placing scripts in the header is not a good solution. Hosting a site in Europe with Google scripts (from American servers) in the header slows a site significantly.
Sucha an option exists in C2008 (currently in beta).
CS Documentation | Nintendo Wiikly
Copyright© 2008 Telligent Systems Inc. All rights reserved CommunityServer.com • Telligent.com