[3.0] Error: add_to_cart not working
-
My plugin has an add to cart button, which triggers the following function.
if($woocommerce->cart->add_to_cart( $final_product_id, $_REQUEST['wtd_design_data']['qty'], $final_custom_variations_id, $arr, null ) ) { echo 'cart_updated'; if(!isset($_SESSION['wtd_cart_id'])) { $_SESSION['wtd_cart_id'] = $uIds; } }
After 3.0 update, this is returning false. WP_DEBUG did show any errors, I couldn’t find a way to debug this. I turned back to old version of woocommerce. One thing I found in an error_log file is the following message:
The “add_to_cart_fragments” hook uses out of date data structures and function is deprecated since version 3.0.8. Replace with woocommerce_add_to_cart_fragments.
I don’t know if this is related but I searched for “add_to_cart_fragments” and can’t find any information.
If you don’t know what can be the cause of this, if you know a way to debug, please let me know.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘[3.0] Error: add_to_cart not working’ is closed to new replies.