0

In WooCommerce, i've disabled quantities to be shown in the settings page (Woocommere > Settings > Products > Inventory > Stock Display Format), however if someone wanted to see how much you had in stock, all they'd need to do is just enter a large number until it threw an error: https://screencast.com/t/JZppIFAaBH

I'm by no means an expert in PHP, and in my research I found a similar topic from a few years ago here: Remove the stock quantity from WooCommerce cart error messages but I was unsuccessful in making that code work in the functions.php file. I'm not sure if something has changed since then. Can anyone provide any input in how I can modify the code in WooCommerce to just not toss out the actual inventory numbers on the front end?

Paul
  • 1
  • Have you tried to enable backorders, that allow customer to enter greater quantity values than available in the stock without any message. That seems to be the solution for you. – LoicTheAztec Aug 20 '19 at 17:49
  • yes, but backorders aren't really what we'd like to do. It would be ideal if we could configure woocommerce to say something like '10+ left in stock' instead of 'Value must be less than or equal to 289' as we don't want to show how much we actually have in stock, but still disallow backorders. – Paul Aug 21 '19 at 15:00

0 Answers0