Results 1 to 10 of 2161

Hybrid View

  1. #1
    Join Date
    Dec 2005
    Posts
    1,509
    Plugin Contributions
    6

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by fakeDecoy View Post
    I think I identified a bug in version 1.2.2 of this mod. I found in AWStats that I'm getting calls to this file on my domain resulting in 404 errors:

    /google-analytics.com/ga.js

    I guess what it's supposed to do is call http://google-analytics.com/ga.js, right? I searched for the text /google-analytics.com/ga.js in zencart and found the below code in this file:

    /home/myaccount/public_html/includes/templates/mytemplate/google_analytics/google_analytics.php

    Code:
    document.write(unescape(\"%3Cscript src='\" + gaJsHost + \"google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E\"));
    Am I interpreting this correctly as what's causing the bug? How should I modify the code to fix it? I'm actually not using the ga.js code any more as of the other day, but perhaps this is what was causing the missing data with ga.js tracking from this mod in the first place.

    I'm not sure what store page called the /google-analytics.com/ga.js file, because AWStatus only tells me the referrer was /index.php, which is the index page of my store and could mean any number of pages. But the above is the only code I found that seems to be calling /google-analytics.com/ga.js.
    Don't edit that info or you're going to cause real mess.

    That code is the exact code which Google tells you to insert (with that exact url) from inside Google Analytics. So unless there was an issue on Google end (temporarily?) then I don't think that the url is the issue.

    If that was the simple fix then Google would have likely found it long ago.

    In fact, that url "google-analytics..." is one Google uses to run some of the analytics applications so it should be fine.

    If you want to take a look at the code they tell you to insert to see it is the actual link they provide then simply login to your Google Analytics account, click on the "Edit" link from the main dashboard next to the website profile you want to edit and then on the next page click the "Check Status" link (upper right).

    This will bring you to a page where you can actually see the code (both ga.js version and legacy version).

    Hope that helps!
    Last edited by econcepts; 13 May 2009 at 01:10 PM. Reason: added info
    Eric
    20 Ways to Increase Sales Using Zen Cart
    Zen Cart contribs: Simple Google Analytics, Export Shipping Information

  2. #2
    Join Date
    Feb 2009
    Posts
    43
    Plugin Contributions
    0

    Default Re: Simple Google Analytics - Support

    Hello,
    I have read some of your posts on SGA. What I have done is that I added the analytics code in the header file - i know this is not the best way to do - but it works. I don't know what the implication would be though. This was just a test but it works - ran check status at Google analytics and confirmed ok ;-)

    I wanted certain meta tags to be on all my pages so I followed the instruction as mentioned here - https://www.zen-cart.com/tutorials/index.php?article=62

    Following this intructions to achieve my add on meta tags. At the end of the header file I added Google analytics.

    Has anybody tried this ?
    Anybody experienced any problems whilst using this.

    I will be using traditional method to install SGA anyways but the alternative method does the trick too.
    I am quite keen to know if anybody here has done this before.

    Thanks in advance

  3. #3
    Join Date
    Feb 2008
    Posts
    129
    Plugin Contributions
    0

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by noobuser View Post
    Hello,
    What I have done is that I added the analytics code in the header file - i know this is not the best way to do - but it works. I don't know what the implication would be though.
    Hi,

    I believe the issue is when Google will be called. If the code is put in the footer, the calls are made after your page has already loaded which means the visitor won't notice it.

    If it is put in the header, the calls will be made first. So if the Google servers are slow, it will delay your page loading.

 

 

Similar Threads

  1. v150 Simple Google Analytics .sql error !
    By Miff in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 10 Feb 2012, 11:33 PM
  2. Simple Google Analytics-not working
    By RobertG in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 11 Nov 2010, 06:07 PM
  3. Simple (From Google) Analytics Install
    By DagLindt in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 26 May 2009, 10:46 PM
  4. Simple google analytics- help
    By Pet Herbal Remedies in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 1 Oct 2008, 10:37 PM
  5. Simple Google Analytics not working
    By jvanree in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 29 May 2008, 03:46 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg