| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
[PATCH] Update to non-legacy Google Analytics code | ||||
|
|
Thread Tools | Search this Thread |
#11
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
OK, so after making a complete ass out of myself, I successfully patched my installation of X-Cart.
Sorry for the false alarm, Jon...
__________________
X-Cart Gold 4.1.10 XCSEO Pro 1.1.7 IIS 7 / Windows 2008 PHP Version 5.2.6 MySQL Version 5.0.51a |
|||||||
#12
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
Quote:
Just HAD to scare off everybody That's okay, I'm sure all of the initially scared users will start to creep back to this thread |
|||||||
#13
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
I do have a question about the GA code that should show after applying this patch.
The old GA code looks like this in my "View Source" Quote:
The new GA code should look like this: Quote:
Is the new GA code what we should be seeing in our pages after applying the GA Module patch?
__________________
X-Cart Gold 4.1.10 XCSEO Pro 1.1.7 IIS 7 / Windows 2008 PHP Version 5.2.6 MySQL Version 5.0.51a |
|||||||
#14
|
|||||||||
|
|||||||||
Re: [PATCH] Update to non-legacy Google Analytics code
Yes, that looks about right AG9V...
<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-xxxxxx-x"); pageTracker._initData(); pageTracker._trackPageview(); </script> Where UA-xxxxxx-x is your GA Account ID check here too... https://www.google.com/support/googleanalytics/bin/answer.py?answer=55480&hl=en_US Regards, Doms
__________________
Doms kube v4.1.9 |
|||||||||
#15
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
After the patch, you should see something like this:
Code:
The difference is that google's original code detects HTTPS, and writes it's url accordingly for the .js file. The google analytics module in X-Cart detects HTTPS in the PHP code, and determines the URL, so that the JS code is simplified. Cheers |
|||||||
#16
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
Thanks for this patch! Works great
__________________
X-Cart Gold 4.1.10 XCSEO Pro 1.1.7 IIS 7 / Windows 2008 PHP Version 5.2.6 MySQL Version 5.0.51a |
|||||||
#17
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
One thing that is missing intel that I noticed in the diff is that the new eCommerce tracking code data is not in there.
|
|||||||
#18
|
|||||||
|
|||||||
Re: [PATCH] Update to non-legacy Google Analytics code
Quote:
Updated original post with new diff containing ga_commerce_form.tpl changes. Really, I don't believe it matters much as the new ga.js file supported the utmtrans method, but this update should remove any doubts. Cheers. |
|||||||
#19
|
|||||||||
|
|||||||||
Re: [PATCH] Update to non-legacy Google Analytics code
If the in product titles or parthner or .... is found " - You need to escape it...
Examples: PHP Code:
|
|||||||||
#20
|
|||||||||
|
|||||||||
Re: [PATCH] Update to non-legacy Google Analytics code
qualiteam has an official patch for this as well. Awesome work though thank you for sharing!
__________________
X-Cart 4.7.8 Pro php 7.x |
|||||||||
|
|||
X-Cart forums © 2001-2020
|