Jump to content
osCoders

Google Analytics module

Recommended Posts

Paul,

Yes you are right , it should be 'javascript'. I think I read that that had been fixed in the latest download.

Share this post


Link to post
Share on other sites

Instead of placing the code in every page, can we place it in the footer.php or header.php

 

Would it work ?

Share this post


Link to post
Share on other sites

I am wondering why everyone is saying that the code must be between the head tags but yet google themselves say to put it right above the </body> tag?

Share this post


Link to post
Share on other sites
Instead of placing the code in every page, can we place it in the footer.php or header.php

 

Would it work ?

 

 

I put the code in footer.php on a few sites and it works fine.

 

You will still need to do the stuff on checkout_success.php though if you want to track how much you sold etc.

Share this post


Link to post
Share on other sites
I have tired the mod and it did not Work.

 

Not even once did it register any Sale.

If you don't use the code and only define a conversion goal (being your checkout process with checkout success at the end) you have something.

Share this post


Link to post
Share on other sites

Hi, will this module work with the Purchase Without Account contribution? It appears to destroy the session before the page is loaded, so presumably the customer_id, etc. would not be available in the body. Anyone implemented these two together?

 

Thanks!

Amit

 

Hello All,

 

This is the support thread for the "Google Analytics module".

 

This module allow you to integrade the advanced e-commerce Analysis provided by the new Google service named Analytics ( more info on the official page: http://www.google.com/analytics/ ).

Best regards,

Clement

Share this post


Link to post
Share on other sites

Hi, Can some of you tell me how to get Google Analytics' invitation code? Does it work like gmail, need someone to send the invitation to you? Thanks.

Share this post


Link to post
Share on other sites
Hi, Can some of you tell me how to get Google Analytics' invitation code? Does it work like gmail, need someone to send the invitation to you? Thanks.

No, you have to add your email to Google's list and every time Google has room again a bunch are invited by Google. First in, first out I guess.

Share this post


Link to post
Share on other sites
Hi, will this module work with the Purchase Without Account contribution? It appears to destroy the session before the page is loaded, so presumably the customer_id, etc. would not be available in the body. Anyone implemented these two together?

 

Thanks!

Amit

 

Anyone mange to get this working? I would be interested in knowing how to get them working together.

 

cheers

Share this post


Link to post
Share on other sites

Hooray! .. I finally got this to work, sort of.

 

I am finally able to get the transaction data but I can see it from the page inside a text box. Is it supposed to be visible from the page? How do I hide the information in the form?

 

Thanks. Lyle

Share this post


Link to post
Share on other sites

BEWARE OF GOOGLE ANALYTICS

 

Right now there is some error with Google Analytics, and if you have inserted the tracking code according to this contribs install file your site will just show a blank page for quite some time. When it finally have finnished loading you will have an javascript error message in your browser.

 

If you decide to insert the tracking code after Googles guidelines your site will be fully loaded quite fast, but it will keep looking for googles tracking stuff and you will finally end up with the javascript error message.

 

So perhaps the the install-file for this contrib should be updated;

Instead of insert the tracking code before the </head>, it should be inserted before the </body>.

However the problem with GA still persist, but this can reduce the drop of sales.

 

This problem occurred yesterday as well, so it is not a one time incident.

 

// Fredrik

Share this post


Link to post
Share on other sites

I've added this contribution a few weeks ago but despite receiving some purchases and making some for testing, I don't see any data on my google analytics e-commerce module, it just displays zero.

 

User tracking it's OK, just the e-commerce part isn't working despite that the installation went OK and the correct Google analytics account number was entered.

 

Is there anything else I should do? (considering a default installation, no OsCommerce files changed, just replaced the old files with the one in the contrib)

 

Thanks

Share this post


Link to post
Share on other sites
Hooray! .. I finally got this to work, sort of.

 

I am finally able to get the transaction data but I can see it from the page inside a text box. Is it supposed to be visible from the page? How do I hide the information in the form?

 

Thanks. Lyle

 

I hope you already solved this problem in this 20 days, but here is the solution:

You yust need to put the form display in extra: <div style="display:none"> --- content --- </div> tag :)

Hope that helps :)

Share this post


Link to post
Share on other sites
I hope you already solved this problem in this 20 days, but here is the solution:

You yust need to put the form display in extra: <div style="display:none"> --- content --- </div> tag :)

Hope that helps :)

 

 

That worked! Thanks..

 

before I had this

 

<form style="display:none;" name="utmform">

 

I thought it should have worked but it did not.

 

Thanks for your help.

 

Lyle

Share this post


Link to post
Share on other sites

So it appears there are some mixed results with adding Google Analytics to OSC right now. It's been 11 days since the last post here. Is everyone uninstalling or are just a couple stores having these problems?

 

Are you guys putting the code in the footer.php page or in the head as in the instructions.

 

Thanks for the help ;)

Share this post


Link to post
Share on other sites

I still don't see the results of orders made using the Google analytics code, despite making the appropiate changes I only see traffic results, but no sales reports :(

Share this post


Link to post
Share on other sites
I still don't see the results of orders made using the Google analytics code, despite making the appropiate changes I only see traffic results, but no sales reports :(

 

so do I, I can't see the e-commerce results. :blink: To bad.

Share this post


Link to post
Share on other sites
BEWARE OF GOOGLE ANALYTICS

 

Right now there is some error with Google Analytics, and if you have inserted the tracking code according to this contribs install file your site will just show a blank page for quite some time. When it finally have finnished loading you will have an javascript error message in your browser.

 

If you decide to insert the tracking code after Googles guidelines your site will be fully loaded quite fast, but it will keep looking for googles tracking stuff and you will finally end up with the javascript error message.

 

So perhaps the the install-file for this contrib should be updated;

Instead of insert the tracking code before the </head>, it should be inserted before the </body>.

However the problem with GA still persist, but this can reduce the drop of sales.

 

This problem occurred yesterday as well, so it is not a one time incident.

 

// Fredrik

 

So is this a problem still? or are you able to install without issue. I know that the ecommerce tracking is not working but how bout the main part of the analytics code? Also did you have to insert it in all the pages of the site? or has someone found an easy way to have it included on all the pages?

Share this post


Link to post
Share on other sites
So is this a problem still? or are you able to install without issue. I know that the ecommerce tracking is not working but how bout the main part of the analytics code? Also did you have to insert it in all the pages of the site? or has someone found an easy way to have it included on all the pages?

 

No problem installing the code, indeed there's a "pack" which you can install in case you have the default installation.

 

The thing is the e-commerce code is not working. Despite making succesfull sales with OsCommerce, those results aren't displayed @ google analytics, but those related to traffic and referrers are OK.

Share this post


Link to post
Share on other sites

Hi there I have it working but the code is just above the </head> tag.

 

 

I have just checked the Google Analytics supoort page and it states

 

Finally, once your page is live, select View Source from your browser's menu and look for the code. It should be immediately before the </body> tag of your page and should look exactly as it was provided to you:

 

<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">

</script>

<script type="text/javascript">

_uacct="UA-xxxx-x";

urchinTracker();

</script>

 

Has it changed? most people here have talked about it having to be before the </head> tag?

 

Hmmm wich one is it

 

Cheers

 

Josh

Edited by jaminunit

Share this post


Link to post
Share on other sites

This concerns me as well but with this method we would have the problem of it breaking secure pages.

Edited by Jesse J

Share this post


Link to post
Share on other sites

I'll probably work on the Analytics module next week in order to get it to work with ecomm transaction values and so on. Anyone interested in helping out please PM me, thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×