Created
February 5, 2018 18:27
-
-
Save alexminza/8384d53e4ef8e5c066c42bc559f15775 to your computer and use it in GitHub Desktop.
WooCommerce woocommerce_get_country_locale filter - state selection required for Romania
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_get_country_locale', 'woocommerce_get_country_locale_romania'); | |
function woocommerce_get_country_locale_romania($countries) { | |
//https://github.com/woocommerce/woocommerce/blob/master/includes/class-wc-countries.php | |
$countries['RO']['state']['required'] = true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment