/**
-
Remove Can be Backordered from In Stock Products
*/
add_filter( ‘woocommerce_get_availability_text’, ‘filter_product_availability_text’, 10, 2 );
function filter_product_availability_text( $availability, $product ) {if( $product->backorders_require_notification() ) {
$availability = str_replace(’(can be backordered)’, ‘’, $availability);
}
return $availability;
}
I found this update to the PHP, but it doesn’t completely work.
If the inventory on an item is negative it just says OUT OF STOCK instead of the AVAILABLE ON BACKORDER.
Any advice?
Jesse