Heads up!
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
This article contains PHP code and is intended for developers. We offer this code as a courtesy, but don't provide support for code customizations or 3rd party development.
Use this filter to change the default location for the user geolocation.
Parameters
- None
Examples
Use this filter to change the default location for the user geolocation
Use this code example to use Google autocomplete without the autofill for the user geolocation. Replace the lat and lng values with your default location.
add_filter('frm_geo_default_location', 'set_geo_default_location' );
function set_geo_default_location() {
return array(
'lat' => 40.7831,
'lng' => -73.9712,
);
}