PHP code example of adamb / google-maps-geocoder

1. Go to this page and download the library: Download adamb/google-maps-geocoder library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

adamb / google-maps-geocoder example snippets


$address = "2707 Congress St., San Diego, CA 92110";

$Geocoder = new GoogleMapsGeocoder($address);

$Geocoder = new GoogleMapsGeocoder();
$Geocoder->setAddress($address);

$response = $Geocoder->geocode();