2017 © Pedro Peláez
 

library geo-distance

Find distance between two points on earth. Find closest metro area.

image

naveed125/geo-distance

Find distance between two points on earth. Find closest metro area.

  • Monday, June 5, 2017
  • by naveed125
  • Repository
  • 1 Watchers
  • 1 Stars
  • 11 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 10 % Grown

The README.md

Geo Distance

Calculate distance between two points on earth using longitude and longitude. Can be used to find out the closest metro area based on distance., (*1)

Example:


// 1 Market St. San Francisco, California, USA
$start = array (
  'lat' => 37.793629,
  'long' => -122.394264
);

// Pier 39, San Francisco, California, USA
$end = array (
  'lat' => 37.808868, 
  'long' => -122.409842
);

$gd = new GeoDistance\GeoDistance();
$distance = $gd->distance($start,$end);

echo "Distance between the two points is: {$distance} miles\n";

The above should output the following:

Distance between the two points is: 1.3532202220106

The Versions

05/06 2017

dev-master

9999999-dev http://github.com/naveed125/geo-distance

Find distance between two points on earth. Find closest metro area.

  Sources   Download

MIT

The Requires

  • php >=5.6.0

 

The Development Requires

php psr-4 geo-distance

05/06 2017

1.0.2

1.0.2.0 http://github.com/naveed125/geo-distance

Find distance between two points on earth. Find closest metro area.

  Sources   Download

MIT

The Requires

  • php >=5.6.0

 

The Development Requires

php psr-4 geo-distance