Question

I have a website where "near locations" are shown for each item, based on the latitude and longitude coordinates stored in a database.

Problem is that this calculated distance is the air-line distance, which differs a lot ferom the actual driving distance.

Google Maps does only have a JavaScript API for driving directions by now, I need it as a web service API to make calls directly from the server.

Is there any possibility to do this?

Was it helpful?

Solution

The Google Maps API has a HTTP service for geocoding, but not for directions. You can only access that functionality through the Javascript API. You could hack it, but it would break Google's ToS.

More discussion here.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top