Skip to content

Instantly share code, notes, and snippets.

@bradleysa
Created April 22, 2022 07:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bradleysa/82204368ac0ef82813f12480cc75e8c9 to your computer and use it in GitHub Desktop.
Save bradleysa/82204368ac0ef82813f12480cc75e8c9 to your computer and use it in GitHub Desktop.
WC: Hide Coupon Field on Checkout Page
function hide_coupon_field_on_checkout( $enabled ) {
if ( is_checkout() ) {
$enabled = false;
}
return $enabled;
}
add_filter( 'woocommerce_coupons_enabled', 'hide_coupon_field_on_checkout' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment