Get user payment details when payment successfully done in woocommerce [closed]

Yes, after an order created you can get details of it. The woocommerce_payment_complete hook is fired when the payment is completed. The only variable passed is the order id, though from that you can get the order object, and ultimately the user. add_action( ‘woocommerce_order_status_completed’, ‘so_payment_complete’ ); function so_payment_complete( $order_id ){ $order = wc_get_order( $order_id ); … Read more

WooCommerce add_to_cart url not working [closed]

So I ended up making a workaround because I still have no clue what’s happening. I changed the url to point to the product page and I’m using ol’good PHP to get the values and add the product with WooCommerce API. Here’s my code: if(isset($_GET[‘order’]) && $_GET[‘order’] == ‘true’) { $typo = isset($_GET[‘attribute_pa_typographie’]) ? $_GET[‘attribute_pa_typographie’] … Read more

WooCommerce Shop Page Not Found 404

What you’ve done here is changing slug for products. For example : http://localhost:8080/shop/product-category/sample-product as explained in WP, but not your Woocommerce home. Change the base to base default in permalinks settings. Then read after 🙂 If you want to change your “Shop Homepage” go to http://localhost:8080/wp-admin/admin.php?page=wc-settings&tab=products&section=display That’s the good way to do it !

WooCommerce change price in cart [closed]

So the answer to this is instead of placing the code in your functions.php, you create a “woocommerce” folder in your theme folder, and place the “cart” folder and the “cart.php” template file from the woocommerce plugin inside of that. Then you place the same code as in the “woocommerce_before_calculate_totals” action inside the loop of … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)