I have a custom status that I need to set as ‘paid’, in the same sense that the core statuses Processing and Complete are ‘paid’ statuses. I need to do this because WC is synced to accounting software, and the sync is unable to generate a sales receipt for an unpaid order. It works fine when using Complete or Processing
Tag: woocommerce
In woocommerce show the check payment option when an order total is 0 dollars
On my wordpress, woocommerce website I am trying to add something to the function.php of my theme that will enable the pay with check option if the order total is 0 dollars. what I have so far: Obviously set isn’t correct, but I am not sure what to use in place of it. Answer Since the total order is 0
How to set a maximum limit in WooCommerce orders per item & per day
I want to allow only a specific number of orders per product per day on my shop. Any idea which hook do I have to add? Thanks Answer The code below uses the product ID to get the total quantity for the current day. If this is higher than or equal to the $dailyOrderLimit that you set (in my example,
Hide shipping address in WooCommerce new order email notification depending on shipping method id
I want to hide the shipping address if the shipping label is called “Pick up at Rockefeller Store” (but to show for other pickup methods). There are too many ids such as “local_pickup:3” for me to filter through. I enabled the shipping address to be shown in emails/email-addresses.php despite it being a local pickup method. My code attempt: I need
remove_action wc_empty_cart_message not working in WooCommerce
I would like to REMOVE completely the wc_empty_cart_message. My site has no cart. and when the item is removed from checkout the user is redirected to the home page. But then upon browsing to a shop page, the message “your cart is not available whilst your checkout is empty” appears and is completely unnecessary. I have seen many of questions/answers
WooCommerce- SizeInfo button for canvas/paintings. [PHP,Javascript,html,css]
I require a plugin/function to display a size info modal for paintings on WooCommerce. I’ve found many for displaying size charts and tables but none for canvas/paintings. Questions: How do i get the WooCommerce attribute values to use in JavaScript. Solved How do i make the image source changed based on two conditions ( Size & Canvas Type)Solved example: (
WordPress how to check if a query has posts
This code allows me to display to the connected user the list of his written articles. However, I would like to choose the message that appears when no articles have been written (when the list is empty). I know that I need an IF statement but I don’t really know where to put it and with which data. I would
WooCommerce: “You Only Need x pieces to Get Free Shipping!” @ Cart
Each product weighs is 1kg. From the second product onwards (so 2kg) shipping is free. how can I get this notice to appear?: you Only Need x pieces to Get Free Shipping! Thank you Answer Following from https://www.businessbloomer.com/woocommerce-add-need-spend-x-get-free-shipping-cart-page/ where I believe you got the snippet from, and based on your statement (basically if Cart is not empty and there is
Calculate and update product price in cart – WooCommerce
I’m creating a WooCommerce (Version 5.6.0) site where users can buy foam products and the prices are calculated on the archive page. Basically, the users enter the dimensions and the price is calculated based on a formula. I’m currently struggling with updating the prices in cart, I don’t have previous experience in customizing the products and prices at this level,
Several issues when using woocommerce_get_availability hook
Im trying to show an ‘out of stock message’ on the single product page for products that are out of stock. I have this code in my functions.php I get the following error: Notice: stock was called incorrectly. Product properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/plugins/woocommerce/templates/single-product.php’), wc_get_template_part, load_template, require(‘/themes/mytheme/woocommerce/content-single-product.php’), do_action(‘woocommerce_single_product_summary’), WP_Hook->do_action, WP_Hook->apply_filters, woocommerce_template_single_add_to_cart, do_action(‘woocommerce_simple_add_to_cart’), WP_Hook->do_action, WP_Hook->apply_filters, woocommerce_simple_add_to_cart,