Hello,
In VirtueMart 1.1.9 / Joomla 1.5.26 I used the following plugin to track conversions for Google Analytics:
http://extensions.joomla.org/extensions/extension-specific/virtuemart-extensions/virtuemart-stats/20861 (http://extensions.joomla.org/extensions/extension-specific/virtuemart-extensions/virtuemart-stats/20861).
But it isn't compatible with VirtueMart 3 / Joomla 3.3.6.
I've searched the forum / internet but didn't find something which should certainly work as simple as the above plugin.
Does someone know a similar simple plugin or a step by step solution to track the conversions for Google Analytics in VirtueMart 3?
Jeroen
Anyone?
Personally I always recommend to use http://piwik.org/, because with piwik you own the tracking data instead of notifying Google about every click on your website.
There is a free piwik plugin for VirtueMart here: http://extensions.virtuemart.net/statistics
Dear jjk,
I also prefer Piwik, because it is working perfect for the VM2 version.
I installed it now also on a vm3 website, but this is not compatible yet.
When opening a product I get below error
Notice: Trying to get property of non-object in ..../plugins/system/istraxx_vmpiwik/istraxx_vmpiwik.php on line 273
When going to the cart I get this error
1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'FROM JOIN lepch_virtuemart_categories using (`virtuemart_category_id`) WHERE =' at line 1 SQL=SELECT FROM JOIN lepch_virtuemart_categories using (`virtuemart_category_id`) WHERE = "9"
so currently this is also not compatible with VM3.
Would you know if this plugin can and will be updated?
Kind regards,
Enriko
Quote from: Enriko on January 02, 2015, 21:59:44 PM
so currently this is also not compatible with VM3.
Would you know if this plugin can and will be updated?
I wasn't aware of this. Don't know if the plugin will be updated soon. I just sent a corresponding question to the developer.
You can add your Google tracker code to the confirm $html in your payment plugin if your only wanting to track completed sales
Hello
Yes you are right. The extensions is not compatible actually with J3.
I have done some tests also with the latest Piwik
I will do a release, but i have to check with J25+VM2, and J25/J3 +VM3.
I will keep you informed when a new release is available.
Hi alatak,
Do you have a possible date for the release of you J3 + VM3 plugin?
I already have a production site online using J3 + VM3 (with Piwik 2.10.0) and if you need a beta tester i'm available.
Is the Piwik tracker compatible with VM 2.6.14
I guess alatak remembers we put a lot of time and effort to make the Plugin running but it never did perfectly. Unfortunately the Piwik team was as bad as possible to support the creation of the Plugin and even didn't supply a documentation.
So if there are any news for the Plugin I would be of course very interested.
QuoteYou can add your Google tracker code to the confirm $html in your payment plugin if your only wanting to track completed sales
Would you have a piece of code to see how it should look like and where it needs to be inserted to track google analytics.
Do you also have a solution to track abandonned carts?
Thank you
kratzi
it varies with every payment plugin - but you just need to find where the final confirm html is formed and add the code
in the latest vm3 paypal it is plugins\vmpayment\paypal\paypal\tmpl\stdresponse.php
authorize it is in the response received function $html
Thank you for your time and input.
Don't I need to define for google analytics the variables. F.e. what the total amount is called in VM code and the variables for the products in the cart etc.
Perfect solution would be to forward data like total cart price, sku, product, product price to google analytics.
Just to clearify: Is this the code we are talking about?
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-XXXXX-X']);
_gaq.push(['_trackPageview']);
_gaq.push(['_addTrans',
'1234', // transaction ID - required
'Acme Clothing', // affiliation or store name
'11.99', // total - required
'1.29', // tax
'5', // shipping
'San Jose', // city
'California', // state or province
'USA' // country
]);
// add item might be called for every item in the shopping cart
// where your ecommerce engine loops through each item in the cart and
// prints out _addItem for each
_gaq.push(['_addItem',
'1234', // transaction ID - required
'DD44', // SKU/code - required
'T-Shirt', // product name
'Green Medium', // category or variation
'11.99', // unit price - required
'1' // quantity - required
]);
_gaq.push(['_trackTrans']); //submits transaction to the Analytics servers
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
Thank you
kratzi
yes - you would echo that out and replace the data with the correct values..
you need to see what is available in the particular file as values