Title: Default contrycode
Last modified: August 30, 2017

---

# Default contrycode

 *  Resolved [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/)
 * Hi for “Rest of the World” is the contry code AX or does this change??

Viewing 13 replies - 1 through 13 (of 13 total)

 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9465679)
 * Hi again!
    First this is a great plugin! My question is, is the “rest of the 
   world” contry code allways AX???
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466120)
 * Hi again! Or it there a function that can check if it is test of the world?
    
   Contry in list or else
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466291)
 * Hi,
    In the country selector, the country code for “Other countries” is the first
   country that is not in a “price zone”, it’s general that this country be “AX”.
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466292)
 * You can get the current country by wcpbc_get_woocommerce_country();
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466369)
 * Thx, but is there a return call if the customer is from rest of the world?
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466630)
 * Hi,
    you can use:
 *     ```
       if ( ! WCPBC()->customer->zone_id ) {
       //other countries
       }
       ```
   
    -  This reply was modified 8 years, 8 months ago by [Oscar Gare](https://wordpress.org/support/users/oscargare/).
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466711)
 * THX!
    This will work perfectly!
 * I wanted to detect if the customer was in zone “other countries”.
    Than i could
   use
 * if ( WCPBC()->customer->zone_id ) {
    //Is in a Zone }else{ //other countries }
 * Right?
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9466719)
 * Yes!
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9468302)
 * Hi [@brodde](https://wordpress.org/support/users/brodde/),
    If you like the plugin,
   please leave a 5 stars review 😉 Thank you in advance.
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9481993)
 * Hi again Oscar!
    This is a superb plugin. We will zoon upgrade to the pro version,
   as sson we are live with the site.
 * Question?
 * With this function as you have toold i can check if a customer is in a zone or“
   rest of the World.
 * if ( WCPBC()->customer->zone_id ) {
    //Is in a Zone }else{ //other countries }
 * Can i also get the zone (id or name)?
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9484630)
 * Hi again Oscar!
    This is a superb plugin. We will zoon upgrade to the pro version,
   as sson we are live with the site.
 * Question?
 * With this function as you have toold i can check if a customer is in a zone or“
   rest of the World.
 * if ( WCPBC()->customer->zone_id ) {
    //Is in a Zone }else{ //other countries }
 * Can i also get the zone (id or name)?
 *  Plugin Author [Oscar Gare](https://wordpress.org/support/users/oscargare/)
 * (@oscargare)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9484691)
 * Hi,
    yes you can get zone_id, name, etc.. from customer variable WCPBC()->customer-
   >name;// zone name WCPBC()->customer->countries;// zone countries … Regards,
    -  This reply was modified 8 years, 8 months ago by [Oscar Gare](https://wordpress.org/support/users/oscargare/).
 *  Thread Starter [brodde](https://wordpress.org/support/users/brodde/)
 * (@brodde)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9484742)
 * Thx like:
    echo WCPBC()->customer->zone_id;

Viewing 13 replies - 1 through 13 (of 13 total)

The topic ‘Default contrycode’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce-product-price-based-on-countries/assets/icon-
   256x256.png?rev=1976858)
 * [Price Based on Country for WooCommerce](https://wordpress.org/plugins/woocommerce-product-price-based-on-countries/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce-product-price-based-on-countries/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce-product-price-based-on-countries/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce-product-price-based-on-countries/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce-product-price-based-on-countries/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce-product-price-based-on-countries/reviews/)

 * 13 replies
 * 2 participants
 * Last reply from: [brodde](https://wordpress.org/support/users/brodde/)
 * Last activity: [8 years, 8 months ago](https://wordpress.org/support/topic/default-contrycode/#post-9484742)
 * Status: resolved