WC_Countries::estimated_for_prefix
Prefix certain countries with 'the'.
Method of the class: WC_Countries{}
Hooks from the method
Returns
String.
Usage
$WC_Countries = new WC_Countries(); $WC_Countries->estimated_for_prefix( $country_code );
- $country_code(string)
- Country code.
Default:''
WC_Countries::estimated_for_prefix() WC Countries::estimated for prefix code WC 10.4.3
public function estimated_for_prefix( $country_code = '' ) {
$country_code = $country_code ? $country_code : $this->get_base_country();
$countries = array( 'AE', 'CZ', 'DO', 'GB', 'NL', 'PH', 'US', 'USAF' );
$return = in_array( $country_code, $countries, true ) ? __( 'the', 'woocommerce' ) . ' ' : '';
return apply_filters( 'woocommerce_countries_estimated_for_prefix', $return, $country_code );
}