Created
August 11, 2016 07:21
-
-
Save xadapter/177523216d8281462c2c39809d68930a to your computer and use it in GitHub Desktop.
WooCommerce - Change a Required Checkout Field to Optional
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
add_filter( 'woocommerce_billing_fields', 'xa_filter_billing_phone', 10, 1 ); | |
function xa_filter_billing_phone( $address_fields ) { | |
$address_fields['billing_phone']['required'] = false; | |
return $address_fields; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment