The problem is simple, in the documentation for the Geocoding API they say ponent filtering exists. (Source: /)
However, if I look at the JS documentation (), it doesn't seem to be implemented. I do however remember that google earlier used to have features implemented but not written about in their API, so I wonder if anyone knows how to achieve ponent filtering with the Google Maps Geocoding API?
Thanks!
The problem is simple, in the documentation for the Geocoding API they say ponent filtering exists. (Source: https://developers.google./maps/documentation/geocoding/)
However, if I look at the JS documentation (https://developers.google./maps/documentation/javascript/geocoding), it doesn't seem to be implemented. I do however remember that google earlier used to have features implemented but not written about in their API, so I wonder if anyone knows how to achieve ponent filtering with the Google Maps Geocoding API?
Thanks!
Share Improve this question edited Dec 30, 2013 at 0:36 Kara 6,22616 gold badges53 silver badges58 bronze badges asked Jun 19, 2013 at 21:17 Alexander KuzminAlexander Kuzmin 1,1208 silver badges16 bronze badges1 Answer
Reset to default 8The documentation seems to of implemented it now. Either way, here is the code:
geocoder.geocode(
{ 'address': address, 'ponentRestrictions':{'country':'GB'}},
function(results, status){
...
});
Used to restrict results to a specific area. A filter consists of one or more of: route, locality, administrativeArea, postalCode or country. Only the results that match all the filters will be returned. Filter values support the same methods of spelling correction and partial matching as other geocoding requests. See Component Filtering in the Geocoding web service for further details.