|
|
Ok!
|
|
|
Ok!
|
|---|---|---|---|---|
| 16 | function getCoordinates($address){
$address = urlencode($address);
$url = "http://maps.google.com/maps/api/geocode/json?sensor=false&address=" . $address;
$response = file_get_contents($url);
$json = json_decode($response,true);
$lat = $json['results'][0]['geometry']['location']['lat'];
$lng = $json['results'][0]['geometry']['location']['lng'];
return array($lat, $lng);
} | координаты, гугл, php | 1050 | Функция получения координат через Гугл на php |