How to get geolocation without using the google api that is now charging a fortune?

Asked

Viewed 84 times

1

I need to get latitude and longitude by address the user types to search for "not ip." but I’m unable to find a way to do this via php without the google api, as it has been charging a high monthly fee since June.. I believe there must be other ways to do it...

Example:

$json_file = json_decode(file_get_contents("http://maps.googleapis.com/maps/api/geocode/json?sensor=false&address=Avenida%20Paulista,%202064,%20Sao%20Paulo"));   


$result = $json_file->results;
$adress = $result->address_components;
$lat    = $adress->geometry->location->lat;

In the file_get url you can place another site that has this information... but what and how??

  • You want an alternative to search for addresses outside Google would be this?

  • However, I need an alternative to search for latitude and longitude and correlation to a given address... , that is to send the address and return the latitude and longitude values all using php.

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.