I want to calculate the driving distance between two locations [the user\'s specified locations], before user starts the driving. I used many formulas and getDistanceFrom in
See directions API of Google Maps
You have just to make a HTTP request: http://maps.googleapis.com/maps/api/directions/output?parameters
http://maps.googleapis.com/maps/api/directions/output?parameters
Answer could be json or xml. You will find the distance in the answer