Category "woocommerce"

Reorder attribute dropdown terms in Woocommerce single variable products

In the Woocommerce single variable product pages, I would like to change the order of the sizing options on the related drop-down menu. Actually It is like thi

WC show notice on add to cart in product pages

I want to add a notice that lets the customers know when they've added a product to their cart that might not be what they intended. So when a product is added

How do you add custom field to woocommerce product attribute

I want to include a simple in the edit attribute form. (/wp-admin/edit.php?post_type=product&page=product_attributes&edit=55) Is this possible? Everyt

Get specific attribute value by varation product id woocommerce

I want to get the attribute value for the variaton id, I tried something but show me the value for 1 month "1 luna". The 120E price is for 12 months. The varia

Apply woocommerce coupon only to the cart total, not to the tax line

I am working on a WooCommerce site. When I apply a coupon on the checkout page, it automatically applies to the tax as well. I only want the coupon code to app

WooCommerce - unset "<product> removed notice…" on cart page

actions and filters. On my WooCommerce site I get the following message when I remove a product from the shopping cart: "<product name>" removed. Undo?

Last order would be re-order in wooCommerce. How is it possible?

I am developing a woocommerce site that has 3 categories like vegetable, Fast food & Fish. vegetables are the main category of his eCommerce site. My client

Make Shipping Method fields Mandatory on Woocommerce checkout page

I'm sure that there is a quick bit of code out there that will solve this issue, but I'm struggling to find it. I have a WordPress/WooCommerce website set-up a

Change user role if checkout custom checkbox is checked in WooCommerce

I'm trying to add a custom function to my child-themes functions.php file where a checkbox is added to the bottom of the billing details form on the checkout pa

Changing currency on checkout with WooCommerce Multilingual Plugin

I'm trying to implement currency change on checkout with WooCommerce Multilingual Plugin. I need a country with COP and the rest of countries with USD. First I

woocommerce get_order_report_data to show order_item_id

I would like to show order_item_id by get_order_report_data() I can use the array to show product id and order id : array( '_product_id' => array(

Applying programmatically a coupon to an Order in WooCommerce3

I'm developing a plugin that creates an order directly (no cart) and applies a coupon. In version 3.0 of the woo API the function add_coupon() has been deprecat

Woocommerce redirect after add-to-cart error

I have being doing research for a few days but still cannot find an answer. I am using Woocommerce without the Single Product page. So I am using urls like htt

Additional price based on cart item count in WooCommerce

Based on "woocommerce change price in checkout and cart page" answer code that change the total price in checkout page, I have added some extra code to count th

Woocommerce shipping address is empty

the option on the site "Default to customer billing address" is selected but the shipping address is still empty. I tried to fix it with code add_action( 'w

How to skip cart page on woocomerce for certain products only?

I added this to my functions.php file : add_filter ('woocommerce_add_to_cart_redirect', 'woo_redirect_to_checkout'); function woo_redirect_to_checkout() { $che

Filter WooCommerce products with post__in and additional meta queries

I am trying to find products that are on sale (including product variations) in addition to another meta_query of price under X. The wc_get_product_ids_on_sale(

Custom WooCommerce shortcode to display product image gallery

I have been tasked with duplicating a WooCommerce product gallery in an internal page (not a product page). As such, I decided to create a Child theme and write

Woocommerce Show default variation price

I'm using Woocommerce and product variations and all my variations have a default variation defined. I would like to know, how I can find the default variation

Woocommerce set all products to featured products from mysql query

I have a woocommerce store and I try to select from Mysql all products and set them as "Featured" products or set them as Non "Featured" products. I have found