Created
March 29, 2022 08:32
-
-
Save cartimize/fd5b8a4e3ac2feda2575beae24096a15 to your computer and use it in GitHub Desktop.
Remove shipping company and shipping zipcode in checkout
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'woocommerce_checkout_fields' , 'custom_remove_woo_checkout_fields' ); | |
function custom_remove_woo_checkout_fields( $fields ) { | |
// remove billing fields | |
unset($fields['shipping']['shipping_company']); | |
// remove shipping fields | |
unset($fields['shipping']['shipping_postcode']); | |
return $fields; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment