Showing products in-stock only
WooCommerce - Showing products in-stock only
PreviousGet formatted price in result title or in contentNextShowing in-stock and backorder products only
Last updated
WooCommerce - Showing products in-stock only
Last updated
This solution is purely configuration based, highly recommended to use. Use solution 2 only if this is not working for some reason. Step 1: Open up the Frontend search settings -> Custom fields panel
Step 2: Make a hidden filter, on the _stock_status custom field, with the value of “instock”:
After saving the options, the filter should be working.
I suggest using this solution if the first one is not working.
What is this, and where do I put this custom code?