WordPress at Your Fingertips
function is not described

WC_AJAX::get_customer_location() public WC 1.0

Locate user via AJAX.

{} It's a method of the class: WC_AJAX{}

No Hooks.

Return

null. Nothing.

Usage

$result = WC_AJAX::get_customer_location();

Code of WC_AJAX::get_customer_location() WC 5.9.0

public static function get_customer_location() {
	$location_hash = WC_Cache_Helper::geolocation_ajax_get_location_hash();
	wp_send_json_success( array( 'hash' => $location_hash ) );
}