Google Analytics problem with added_to_cart event trigger
Hello,
I have a problem with the plugin: https://wordpress.org/plugins/woocommerce-google-analytics-integration/.
For the plugin to work properly, it must be: passing parameters to the added_to_cart event trigger.
My programmer added a fix to the file: /wp-content/themes/betheme/js/woocommerce.js.
You can see the fix here: /wp-content/themes/betheme/js/woocommerce.js?ver=27.6.4 (I will send the entire link privately)
In line 67 has been replaced: $(document.body).trigger('added_to_cart');
to
$(document.body).trigger('added_to_cart', [response.fragments, response.cart_hash, $thisbutton]);
This is required for the plugin Google Analytics for WooCommerce. If the fix is not implemented, after the template update, this part will be overwritten and the problem will return. Can you help me and fix the problem in the new update?
Comments
Hi,
I have not received your private message yet.
However, I passed what you wrote here to the dev team, and we will implement this fix in future updates.
Best regards
Hi,
Thanks for your help, I'm sending the full link now.
I received your private message. Anyway, as I mentioned in my previous message, this fix will be implemented in the upcoming update.
Best regards
That's great, thank you very much for your help.