Hi,
Thanks for letting me know this.
There is already a fix for this issue, if you can download and replace this one file, it should solve for your as well:
https://raw.githubusercontent.com/duracelltomi/gtm4wp/master/integration/woocommerce.php
Have a great day,
Thomas Geiger
Hello!
I could not check right now your fix and see what was changed, but what I meant that it’s possible to do like this:
$order = new WC_Order( $order_id );
if ( $gtm4wp_is_woocommerce3 ) {
$this_order_key = $order->get_order_key();
} else {
$this_order_key = $order->get_order_key();//was just $order->order_key;
}
Greetings!
There was a bug at the top of this file: the $gtm4wp_is_woocommerce3 variable was not populated correctly therefore the wrong branch of if() statement was executed on WooCommerce 3
Thanks!
Update: I compared files in wordpress repository and link you have send – and they are identical without any fixes
-
This reply was modified 6 years, 7 months ago by jurij_c.