This package is abandoned and no longer maintained. No replacement package was suggested.

Easy wrap Google geocoder web service

v2.1 2016-01-04 15:23 UTC

This package is not auto-updated.

Last update: 2022-02-01 12:50:08 UTC


Build Status Simple lib to wrap Google geocoder Web Service


$ composer require rezzza/google-geocoder


You should build on your own the repository :

$googleAddressRepository = new Rezzza\GoogleGeocoder\GoogleAddressRepository(
    new Rezzza\GoogleGeocoder\GoogleGeocodeClient(
        new Ivory\HttpAdapter\CurlHttpAdapter(),
    new Rezzza\GoogleGeocoder\Model\AddressFactory

Then you can use all methods available in the repository :

  • findByPlaceIdWithLanguage($placeId, $language)
  • findByCoordinatesWithLanguage($latitude, $longitude, $language)
  • findByAddressWithLanguage($address, $language)
  • findByLocalityAndCountryCodeWithLanguage($locality, $countryCode, $language)
  • findByLocalityAndCountryCodeAndAministrativeAreaWithLanguage($locality, $countryCode, $administrativeArea, $language)

All these methods will return a Rezzza\GoogleGeocoder\Model\AddressCollection except the first one that will return directly a Rezzza\GoogleGeocoder\Model\Address (as a placeId is uniq).