Question: I am making a basic cart system. My goal is every time the Add to Cart button is clicked, the item is listed in the cart accordingly. I have accomplished only 2 rows, but when the 3rd item is ...

Question: I want to add a 30% discount on the cheapest item in the cart, except if it already has a discount. Based on Cart discount for product that cost less in Woocommerce answer code, this is my code attempt: ...

Question: How can I set a minimum order amount only for Delivery/Shipments (but not for local pickup) and depending on specific post codes? Use Case: A Restaurant delivers in the local village without minimum amount. But the neighbor villages should ...

Question: I’m trying to run a function if a statement is true (product id exist in an array), I will like to exclude a specific product id from this. So far I have the below code which works fine but ...

Question: I am doing a check in the cart to apply a rule that if a item from the chilled category is added, a minimum of 3 chilled category items are required to check out. – This works. However, if ...

Question: I have added input field in product detail page and need to save with cart without any product attribute and new table column. How to do this? Answer: To do this, you can use additional_options by using event-observer. Please ...