I would like to calculate distance between 2 points of latitude and longitude in PHP (NOT IN ANDROID)**i have read about **Haversine Formula and Spherical Law of Cosines for calculate distance between two points but my main motive is get best location difference between 2 points in Meters.
For Example Two devices place at next to each other and that android devices is sending location to server,So we need to take that location of each device and calculate minimum distance between these 2 device in meter.Result from Server after calculation should be like in 2-3 meters when device is placed next to each others
So what are the possible ways to calculate minimum distance between two device in meters when device next to each other on server side
Note : I need to calculate distance which i got in kms or miles which is big difference when device is next to each other. Haversine Formula and Spherical Law of Cosines is i found best way to calculate but i need to do more in these formulas to get minimum difference between 2 device.Not on Android Device. This question is not related to This Question