Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. add_filter( 'woocommerce_get_availability', 'custom_availability', 5, 2);
  2. function custom_availability( $availability, $_product ) {
  3. if ( !$_product->is_in_stock() ) $availability['availability'] = __('Your message', 'woocommerce');
  4. return $availability;
  5. }
  6. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement