Skip to content

Instantly share code, notes, and snippets.

@aderaaij
Created July 24, 2014 10:06
Show Gist options
  • Save aderaaij/e47c34170f82875e9274 to your computer and use it in GitHub Desktop.
Save aderaaij/e47c34170f82875e9274 to your computer and use it in GitHub Desktop.
Remove quantity selector
<?php
/**
* @desc Remove in all product type
*/
function wc_remove_all_quantity_fields( $return, $product ) {
return true;
}
add_filter( 'woocommerce_is_sold_individually', 'wc_remove_all_quantity_fields', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment