I use Google Maps API to get city name in 2 different languages by users' coordinates. Before version 3.5 of the API I was able to use language option in geocoder's request, but since June 8, 2011 this option is removed.
Can someone give me any idea how can I get the city name in two or more different languages with maps' geocoder?
I included the js script with language option something like this - http://maps.google.com/maps/api/js?sensor=false&language=ja
Asked
Active
Viewed 1.6k times
16

Veselin
- 287
- 1
- 2
- 12
-
Can you provide a link to a page with code that isn't working the way you expect? It will make things easier for someone if they can look at what you have and play with it to figure out if something is wrong. – Trott Jun 25 '11 at 17:56
-
My project is still in development and currently it's not online – Veselin Jun 27 '11 at 10:11
1 Answers
22
It seems that the feature has been removed:
We made this change to simplify the API. The Geocoder uses the browser's preferred language, or language specified when loading the API" (Source)
It still work if used directly:

Lucamug
- 792
- 5
- 19
-
@fuchs I can make neither AJAX request nor curl to get and fetch geocoding results. It says "REQUEST_DENIED" on status, but only works through browser. How did you make this work? – jwchang Jan 13 '12 at 02:38
-
@InspiredJW I use server side api to get the geocoding results in the language I need. `$gmaps_url = "http://maps.googleapis.com/maps/api/geocode/json?address=" . $address . "&sensor=false®ion=" .COUNTRY_CODE. "&language=" . $lang; $result = file_get_contents( $gmaps_url ); $gmaps_data = json_decode($result);` – Veselin Sep 21 '12 at 10:50
-
@fuchs I have resolved problem through making server-side api wrapper by myself. Simply call HTTP request through my server but not by XHR. – jwchang Sep 23 '12 at 04:52