daily pastebin goal
36%
SHARE
TWEET

WooCommerce - Customizing locale dependant checkout fields

lorro Aug 2nd, 2018 (edited) 58 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. // WooCommerce - Customizing locale dependant checkout fields
  3. add_filter( 'woocommerce_get_country_locale', 'custom_nz_locale' );
  4. function custom_nz_locale( $locale ){
  5.   $locale['NZ']['state']['required'] = true;
  6.   return $locale;
  7. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top