woocommerce_geolocate_ip

woocommerce_geolocate_ip

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.9.8.1

apply_filters('woocommerce_geolocate_ip') is found 1 times:

  • /includes/class-wc-geolocation.php line 159
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    * @param bool $fallback If true, fallbacks to alternative IP detection (can be slower).
     * @param bool $api_fallback If true, uses geolocation APIs if the database file doesn't exist (can be slower).
     * @return string
     */
    $country_code = apply_filters( 'woocommerce_geolocate_ip', false, $ip_address, $fallback, $api_fallback );
     
    if ( false !== $country_code ) {
        return array(
            'country'  => $country_code,
            'state'    => '',
            'city'     => '',