From ce3e0af3b4e5d28ef40c2107ed4f172766377824 Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Thu, 23 Dec 2010 18:07:31 +0100 Subject: [PATCH] Defines default language and location for the geocoder in the configuration file. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- classes/gmapsgeocoder.php | 3 ++- configs/platal.ini | 7 +++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/classes/gmapsgeocoder.php b/classes/gmapsgeocoder.php index 16a2764..38eff81 100644 --- a/classes/gmapsgeocoder.php +++ b/classes/gmapsgeocoder.php @@ -105,9 +105,10 @@ class GMapsGeocoder extends Geocoder { $parameters = array( 'key' => $globals->geocoder->gmaps_key, 'sensor' => 'false', // The queried address wasn't obtained from a GPS sensor. + 'hl' => $globals->geocoder->gmaps_hl, 'oe' => 'utf8', // Output encoding. 'output' => 'json', // Output format. - 'gl' => 'fr', // Location preferences (addresses are in France by default). + 'gl' => $globals->geocoder->gmaps_gl, 'q' => $address, // The queries address. ); diff --git a/configs/platal.ini b/configs/platal.ini index a8cb4c2..4fcbe42 100644 --- a/configs/platal.ini +++ b/configs/platal.ini @@ -198,6 +198,13 @@ gmaps_key = "" ; URL of geocoding webservice gmaps_url = "http://maps.google.com/maps/geo" +; $globals->geocoder->gmaps_hl +; Default output language. +gmaps_hl = "fr" + +; $globals->geocoder->gmaps_gl +; Default location preference. +gmaps_gl = "fr" ; The lists section contains parameters used to interact with mailman. [Lists] -- 2.1.4