PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

Hide out of stock variations

The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page please
If you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.

Hi,

Is it possible to hide products from search results if the variation searched for is out of stock? (without having to select the 'in stock' filter checkbox)

 

thanks

Update - I found your code in a previous post, and it works great. Thank you!

 

add_filter('woof_get_request_data', 'my_woof_get_request_data');

function my_woof_get_request_data($data){
$data['stock']='instock';
return $data;
}

Thank you for cooperation, Welcome :)