I am attempting to get the long & lat for a list of Canadian cities or preferably, the long/lat for the airport in each city. For commonly named cities I am adding the region parameter but it does not return the response I would expect.
Here is the URL I am querying ... http://maps.google.com/maps/api/geocode/xml?address=London®ion=ca&sensor=false This returns Westminster, London, UK If I add the airport's IATA code I get the desired results ... http://maps.google.com/maps/api/geocode/xml?address=London+YXU&sensor=false This returns London International Airport, London, ON as I had hoped This would be fine if it worked all the time but it does not. For instance with Sydney, both of the following requests return Sydney NSW, Australia ... http://maps.google.com/maps/api/geocode/xml?address=Sydney+YQY&sensor=false http://maps.google.com/maps/api/geocode/xml?address=Sydney®ion=ca&sensor=false To get the desired result I need to add the ccTLD to the address parameter instead of the region as follows ... http://maps.google.com/maps/api/geocode/xml?address=Sydney+ca&sensor=false I just need one consistent method for returning the correct city. Any help is greatly appreciated. -- You received this message because you are subscribed to the Google Groups "Google Maps API" 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-maps-api?hl=en.
