Last active
May 7, 2017 10:35
-
-
Save vyskoczilova/7d9612bc7d306d6bbfe46d5394b4a4e3 to your computer and use it in GitHub Desktop.
Make the phone number not required in WooCommerce 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
add_filter( 'woocommerce_billing_fields', 'wc_kbnt_filter_phone', 10, 1 ); | |
function wc_kbnt_filter_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