shopp_country_zones

filters the country zones (states/provinces) lookup table.

add_filter( 'shopp_country_zones', [callback] )

@param array $zones the country zones (states/provinces) lookup table.

Description

filters the country zones (states/provinces) lookup table.

Example

// register filter callback
add_filter('shopp_country_zones', 'shopp_country_zones_filter');

// create filter function
function shopp_country_zones_filter( $zones ) {
    // ISO 3166-2 entry for the country, indexed by its ISO 3166-1 alpha-2 code
    $zones['AD'] = // iso 3166-1 code for Andorra
        //  ISO 3166-2 codes
        // parishes of Andorra
        // http://en.wikipedia.org/wiki/ISO_3166-2:AD
        array(
            '07' => 'Andorra la Vella',
            '02' => 'Canillo',
            '03' => 'Encamp',
            '08' => 'Escaldes-Engordany',
            '04' => 'La Massana',
            '05' => 'Ordino',
            '06' => 'Sant Julià de Lòria'
            );
    return $zones;
}

See Also

You must be logged in to post a comment.

© Ingenesis Limited. Shopp™ is a registered trademark of Ingenesis Limited.

Skip to toolbar