(Note: You're currently using the Version 2 Maps and Geocoding APIs,
which are now deprecated. You may want to consider using the Version
3 APIs.)
.
There is a region biasing parameter ("gl" for V2, "region" for V3),
but it won't produce the strict restriction you want.
A possible workaround is to simply add the country name to your search
query.
.
Examples:
The following two examples demonstrate that region biasing is NOT a
strict restriction. These examples specify the ccTLD for Canada
("ca") in the region biasing parameter, but the results include other
countries.
V2:
http://maps.google.com/maps/geo?output=json&sensor=false&q=100+Rue+Montaigne&gl=ca
V3:
http://maps.google.com/maps/api/geocode/json?sensor=false&address=100+Rue+Montaigne®ion=ca
The following two examples do not use the region biasing parameter;
instead the country name is added to the query. In these examples,
all of the results are from the specified country.
V2:
http://maps.google.com/maps/geo?output=json&sensor=false&q=100+Rue+Montaigne+Canada
V3:
http://maps.google.com/maps/api/geocode/json?sensor=false&address=100+Rue+Montaigne+Canada
I don't know if this workaround will satisfy your requirements in all
cases. I don't know of any better solutions; I'm not an expert on
these APIs.
-- omr
--
You received this message because you are subscribed to the Google Groups
"Google AJAX APIs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-ajax-search-api?hl=en.