disable control minimum quantity woocommerce

I use this plugin (https://it.wordpress.org/plugins/woo-min-max-quantity-limit/) because I need to set for specific products the minimum quantity.

The plugin works fine, but I need to disable control that does not allow you to drop from the minimum amount.

For example :

  • I set minimun quantity 2 for my product ;
  • in frontend I see this product just with number of quantity 2 in woocommerce quantity field.
  • the problem that isn’t impossible decrease quantity below 2.

the function is correct, but I want to disable this. I would see 2, but i must can decrease the quantity.

This is the code inside plugin that force this :

/*Function to manipulate custom minimum and maximum purchase*/
add_filter('woocommerce_quantity_input_args', 'wc_mmax_quantity_input_args', 
10, 2);
function wc_mmax_quantity_input_args($args, $product)
$mmaxEnable = get_post_meta($product->id, '_wc_mmax_prd_opt_enable', true);
$minQty     = get_post_meta($product->id, '_wc_mmax_max', true);
$maxQty     = get_post_meta($product->id, '_wc_mmax_min', true);
if ($minQty > 0 && $maxQty > 0 && $mmaxEnable == 1) {
    $args['min_value'] = $minQty; // Starting value
    $args['max_value'] = $maxQty; // Ending value

return $args;


Read more here: disable control minimum quantity woocommerce

Leave a Reply

Your email address will not be published. Required fields are marked *