Created
January 29, 2013 13:33
-
-
Save coenjacobs/4664271 to your computer and use it in GitHub Desktop.
Removes the Dutch provinces from WooCommerce country dropdown boxes as they are not required for Dutch shops. Will become superfluous once WooCommerce 2.0 is released. Important: Make sure you select 'Netherlands' as country again in WooCommerce settings.
This file contains hidden or 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 | |
/* | |
Plugin Name: WC Remove Dutch Provinces | |
Description: Removes the Dutch provinces from the WooCommerce country dropdown boxes, no need to show these. Will become superfluous once WooCommerce 2.0 is released. Important: Make sure you select 'Netherlands' as country again in WooCommerce settings. | |
Author: Coen Jacobs | |
Author URI: http://coenjacobs.me/ | |
*/ | |
add_filter( 'woocommerce_states', 'cj_woocommerce_states' ); | |
function cj_woocommerce_states( $states ) { | |
$states['NL'] = array(); | |
return $states; | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment