Open braekling opened 8 years ago
btw @braekling we've added support for Woocommerce, MemberPress and EasyDigitalDownloads: https://github.com/matomo-org/wp-matomo/tree/master/classes/WpMatomo/Ecommerce
Could potentially copy over the same code into this plugin (would probably just need to rename the namespace etc)? I did some testing but can't guarantee yet it fully works. We haven't received any bug reports just yet though. I'm mainly concerned whether they work with very old versions of the Ecommerce plugins or if it could break something but it seems to work so far.
There's one thing that would maybe need explaining:
https://github.com/matomo-org/wp-matomo/blob/0.2.0/classes/WpMatomo/Ecommerce/Base.php#L85-L101
When it is an ajax request, then we send the tracking request through the PHP tracker instead of JS tracker because I wouldn't be able to add the needed tracking code to the ajax request (or we could add it, but it wouldn't be added to the DOM or it could break things etc). Not sure if that be a problem for you or whether you could do the same.
Thanks a lot, I'll have a closer look at your solution. :)
Integrate Piwik e-commerce functionality and WooCommerce.