I'm trying out the Distance Matrix API but I can't make it work for London Ontario. It always comes back with London UK. My HTTP request is https://maps.googleapis.com/maps/api/distancematrix/json?origins=Ajax+ON&destinations=London,%20ON&key=
All other Candian cities are coming back fine. I can resort to Lat and Lon but I just wanted to check if there is a workaround by using the city name.
Thank you for your help!
MJ
Related
I'm trying to figure if there is a way to ask the Google Map Api to know if a random gps coordinates like :
48,277373
2,4883883
Is accessible by pedestrian ?
It should be possible because if I ask Google Map to lead me in the middle of a river, it will lead me just on the nearest point before the water.
But I'm not sure how about I can get this information by providing the coordinates.
Thanks for your help :-)
I am trying to geocode NYC high schools by using the Maps Geocoding API and the unique BN code assigned to each high school. For example, typing K733 into Google Maps results in a marker on MESA Charter High School in Brooklyn, NY. However, when I use the API url like so:
https://maps.googleapis.com/maps/api/geocode/json?address=K733
I keep getting "ZERO_RESULTS". I've also tried using the Places API and I've gotten the same results. Can anyone point me in the right direction? Is it even possible to pull this information from Google Maps?
It not possible to use unique BN codes for Maps Geocoding API because the address component requires postal address
address — The street address that you want to geocode, in the format
used by the national postal service of the country concerned.
Additional address elements such as business names and unit, suite or
floor numbers should be avoided. Please refer to the FAQ for
additional guidance.
It seems that the Routing API requires a Lat/Lon pair to be supplied to the Waypoint parameter. I've seen other APIs that allow for the actual address to be passed, instead of the Lat/Lon. I'm wondering if anyone knows of a way to do this with the Here.com API. In many instances I can obtain the Lat/Lon first, but in one instance it's proving to be a headache, especially given the nature of the way that the REST APIs work and the fact that I'm trying to batch-process a small group of addresses at a single time. Any help would be appreciated.
Unfortunately Routing API needs a waypoint in lat, lon and required a Geocoding as a pre-requisite.
Maybe a not so nice workaround if you are facing issues with Geocoding, the Duck Duck Go provides a syntax
https://duckduckgo.com/?q=!here Junghofstraße 14,60311 Frankfurt am Main,Germany, Germany&ia=about
But you will stll have to extract the lat,lon from the final redirected url.
I am using Google Maps API v3 Distance. It has worked well for the majority of the addresses in my database. However, it seems like some addresses just aren't available in Google Maps, and it seems to pick the closest street address match which could be way off. I would expect Google Maps in this case to provide an answer based on city and zip. Does anyone have a solution? I've thought of double checking mathematically by geocode and checking Yahoo maps(or other sites) for the ones that are way off but that adds processing time and is not a very elegant solution. There must be some setting I'm missing or other such work around.
Thanks!
BTW shout out to the new Json Serializer! Well it was new to me anyways.
How are you formatting the address you are sending ?
I've used the Google Maps API to do some reverse geocoding and if a street could not be found (due to a typo or what have you) Google would return the lat lng for the historic town center.
I structured addresses as Country, city cityzip, street nr.
You should use the location_type of the geometry object to determine what accuracy was returned. I suggest checking to see if the returned resulsts indicate whether a result is anything other than ROOFTOP or RANGE_INTERPOLATED.
I am creating a business directory website which has street addresses stored in the database. I would like to calculate the distance from a given zipcode to the street address using google maps in ASP.Net.
I don't even know where to begin. Can someone please help?
please see the links below
http://briancray.com/2009/04/01/how-to-calculate-the-distance-between-two-addresses-with-javascript-and-google-maps-api/
http://briancray.com/2009/06/23/calculate-driving-distance-google-maps-api/
http://www.ehow.com/how_5142324_calculate-distance-google-maps.html