Skip to content

Instantly share code, notes, and snippets.

Sajad Dehshiri sajaddp

Block or report user

Report or block sajaddp

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@sajaddp
sajaddp / PHP-Get-Geocode-from-Address
Created Jul 22, 2017 — forked from madeinnordeste/PHP-Get-Geocode-from-Address
PHP - Get Geocode (lat, long) from Address
View PHP-Get-Geocode-from-Address
<?php
$address = 'avenida+gustavo+paiva,maceio,alagoas,brasil';
$geocode = file_get_contents('http://maps.google.com/maps/api/geocode/json?address='.$address.'&sensor=false');
$output= json_decode($geocode);
$lat = $output->results[0]->geometry->location->lat;
$long = $output->results[0]->geometry->location->lng;
You can’t perform that action at this time.