Site icon Learn Web Development & Programming, Artificial Intelligence, WordPress, Shopify Articles

How to Set Maximum weight for every order in WooCommerce

max_woocommerce

Hello friends, In this article we w’ll learn “How to set Maximum weight for every order in WooCommerce“. Let’s start if we want to set a limit of 30kg for each order. In WooCommerce, there are several ways to set the parameters for WooCommerce purchase limit.

Here we will use the “woocommerce_check_cart_items” action which is provided by WooCommerce to run the functions and execute the code.

Setting a Maximum Weight for WooCommerce Purchase Limit

Many online stores don’t allow their customers to checkout cart if his purchase product weight exceed a pre set limit.

You need to place the following code in the function.php, located in theme folder.

Exit mobile version