Ecommerce Tracking Issue with Custom Template

Questions and answers about ShopSite Custom Templates

Ecommerce Tracking Issue with Custom Template

Postby apeerenb » Tue Oct 11, 2011 1:23 pm

Hello,

My client is using ShopSite for his ecommerce website: www.tecratools.com. Sometime at the beginning of July, Google Analytics stopped attributing revenue data to the proper medium (organic, PPC, direct, etc) and all revenue fell under Direct traffic. He uses extensive custom templates and says he has not made any change to the Google Analytics code.

I don't believe it is any issue with the basic Analytics code itself because there has not been any significant change to traffic that corresponds to the change in revenue attribution. And I know we are still getting conversions through other mediums because PPC traffic through AdWords (tracked with the Conversion Tracking code) is working. I can see transactions and revenue in AdWords only.

Any thoughts on how we can fix the ecommerce tracking?

Thanks.
apeerenb
 
Posts: 5
Joined: Tue Oct 11, 2011 1:16 pm

Re: Ecommerce Tracking Issue with Custom Template

Postby ShopSite Lauren » Wed Oct 12, 2011 3:16 pm

My guess is that the Google Analytics code on your pages is hard coded in the templates. The reason I think this is that the code is slightly different than the code that ShopSite outputs for Google when you set it up. Google has been changing their tracking code, I think there have been three different main types in the last year and a half. ShopSite only displays two main types (used to display all three, but one is dated so in newer versions of ShopSite it is no longer listed) but the code that is on your pages is not the same as either of the code sets that ShopSite outputs. All that said, I would suggest either removing the hard coded Google Analytics code and using the ShopSite options (see if that fixes the issue), or recopy and repaste the Analytics code from Google into your custom template.

There is a line of code in the GA code that ShopSite outputs that is for the pageTracker._initData(); that is not in the code on your pages. My guess is that line is what would resolve the issue. I am not sure what would stop that information from being sent, whether it is some change that seemed like it wouldn't change anything but did, or if the Google code, in Google making changes, modified the way that it worked, or some other thing, I am not sure. But it is likely that by updating the Google Analytics code to their newest tracking code, that you will get more information than before.
- ShopSite Lauren
Contact me for help with any of your
custom ShopSite template questions.
ShopSite Lauren
 
Posts: 887
Joined: Fri Aug 11, 2006 1:35 pm
Location: Orem, UT

Re: Ecommerce Tracking Issue with Custom Template

Postby apeerenb » Thu Oct 13, 2011 10:46 am

Yes, the GA has been hard-coded into his custom templates. Everything else is working fine with regards to Analytics, except for attributing revenue to the correct traffic source. I will try adding in that specific line you mentioned first to see if it fixes the issue. Does it matter where exactly within the GA code I place it?
apeerenb
 
Posts: 5
Joined: Tue Oct 11, 2011 1:16 pm

Re: Ecommerce Tracking Issue with Custom Template

Postby ShopSite Lauren » Thu Oct 13, 2011 12:28 pm

The code would look like the following:

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-801718-2");
pageTracker._initData();
pageTracker._trackPageview();
</script>
- ShopSite Lauren
Contact me for help with any of your
custom ShopSite template questions.
ShopSite Lauren
 
Posts: 887
Joined: Fri Aug 11, 2006 1:35 pm
Location: Orem, UT

Re: Ecommerce Tracking Issue with Custom Template

Postby apeerenb » Thu Oct 13, 2011 2:44 pm

And that would go on the main GA code? Why not the Ecommerce tracking code?
apeerenb
 
Posts: 5
Joined: Tue Oct 11, 2011 1:16 pm

Re: Ecommerce Tracking Issue with Custom Template

Postby ShopSite Lauren » Mon Oct 17, 2011 3:21 pm

The GA code on the thank you page is slightly different because it needs to pass the specific order information. If you are hard coding the code, then you will need to find out what the code is and change it for the thank you screen (I think this is the only place it is different, but I am not positive). My suggestion would be to remove the hard coded code and go with the build in ShopSite GA integration. This will automatically add the correct code for all pages.
- ShopSite Lauren
Contact me for help with any of your
custom ShopSite template questions.
ShopSite Lauren
 
Posts: 887
Joined: Fri Aug 11, 2006 1:35 pm
Location: Orem, UT

Re: Ecommerce Tracking Issue with Custom Template

Postby apeerenb » Tue Oct 25, 2011 10:25 am

Hi Lauren,

Okay, so it sounds like that extra line of code should be placed on each instance of the GA code, including the Thank You page. But there shouldn't be fixes made to the Ecommerce tracking code itself. Is that correct?

And my client said that he's tried the ShopSite GA Integration in the past and it didn't work with his old templates. Are you able to see what version he's on and confirm that it will work?

Thank you for your continued help.
apeerenb
 
Posts: 5
Joined: Tue Oct 11, 2011 1:16 pm


Return to Custom Template Questions

Who is online

Users browsing this forum: No registered users and 8 guests

cron