smartfaq
SmartFAQ is developed by The SmartFactory (http://www.smartfactory.ca), a division of InBox Solutions (http://www.inboxsolutions.net)

How do I use Google Analytics with my website?
Requested and Answered by Bluenova on 2006/5/10 9:07:12 (16645 reads)
Sign up for Google Analytics here

Once your account is activated, login to Google Analytics and setup your profile.

At the end of setting up your profile you will be given some code to add to your website, copy this code.

Edit this file on your website:
/*XOOPSINSTALL*/themes/*YOURTHEME*/theme.html

(/**/ denotes: This will be different for your website.)

Scroll to the end of the file and find:
</body>
Paste the code immediately BEFORE this tag. Save the file.

Browse to your xoops website administration go to:
System Admin >> Preferences >> General Settings
Scroll down to:
'Update module template .html files from themes/your theme/templates directory?' and select 'Yes'

Browse to a couple of pages on your website, then go back to Google Analytics and click 'Check Status'. The status should now say 'Waiting for Data'.

If it still says 'Tracking Not Installed' Google Analytics cannot see the code, please make sure you have followed all the steps above.

Go back to:
System Admin >> Preferences >> General Settings
Scroll down to:
'Update module template .html files from themes/your theme/templates directory?' and select 'No'

The setup is now complete. Google Analytics will continue to say 'Waiting for Data' for the next 12 to 24 hours, after that it will say 'Receiving Data' and you will be able to view your site stats.


The comments are owned by the author. We aren't responsible for their content.
  • Just popping in

 why not after?

I have the script after </body> and everything is OK.

 

 Re: why not after?

I have no idea, google say before.

 
  • Just can't stay away

 Have to wait...

You forgot to mention:

Quote:

Google Analytics has experienced extremely strong demand. We are sending invitations to new users to sign up as we add more capacity. If you would like to receive an invitation code, please enter your email address below and we will send you one as capacity becomes available.


Perhaps this is location-oriented, but it's worth mentioning. I have other Google features and still need to wait.

 

 Re: Have to wait...

It's not location orientated. As with most Google products they like to roll things out slowly so not to overload themselves. It took me about 3 weeks to receive an invitation. I imagine they will eventually open it fully, but will they ever do that with gmail? I didn't mention it cause it's not relevant with how to set it up, and it'll probably open fully later. I did say once your account is activated.

 
  • Just popping in

 Re: Have to wait...

have someone invitation code?

 

 Re: Have to wait...

Quote:

have someone invitation code?

Invitations can only come from google, you will need to sign up and wait a few weeks.

 
  • Just popping in

 Re: why not after?

I followed the procedure and I added the javascript just before the </body> tag:

<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXXX-X";
urchinTracker();
</script>

Of course, replacing the UA-XXXXXX-X with actual numbers.

Google analytics, gives me a Tracking Unknown stating that it can't find the tracking code.

I also checked to make sure that its on the live pages, and it is.

Should I wait for a day at least until it picks it up?

Does anyone know why its not picking up?

I'm using XOOPS ver 2.2.2

 
  • Just popping in

 some sort of error

I dont have an option aboout updating html templates etc.

I tick yes for:
Check templates for modifications ?

If this option is enabled, modified templates will be automatically recompiled when they are displayed. You must turn this option off on a production site.

And i get:
This page cannot be displayed due to an internal error.

If you are the administrator of this site, please visit the XOOPS Troubleshooting Page for assistance.


when trying to get to nay part of my forum.

If go back and check no it starts working again.