Subversion Repositories eFlore/Applications.cel

Compare Revisions

Regard whitespace Rev 969 → Rev 970

/trunk/jrest/services/CoordSearch.php
21,11 → 21,11
parent::__construct($config);
$this->adresse_service_geonames = $this->config['cel_db']['url_service_geo_geonames'];
$this->adresse_service_local = $this->config['cel_db']['url_service_geo_local'];
$this->adresse_service_geonames = $this->config['cel']['url_service_geo_geonames'];
$this->adresse_service_local = $this->config['cel']['url_service_geo_local'];
$this->nom_service_geocoding = $this->config['cel_db']['nom_service_geocoding_geonames'];
$this->nom_service_reverse_geocoding = $this->config['cel_db']['nom_service_reverse_geocoding_geonames'];
$this->nom_service_geocoding = $this->config['cel']['nom_service_geocoding_geonames'];
$this->nom_service_reverse_geocoding = $this->config['cel']['nom_service_reverse_geocoding_geonames'];
}
 
/**
80,6 → 80,10
$commune = $this->affecterValeurParametreOuDefaut($params, 2, '*');
$code_postal = $this->affecterValeurParametreOuDefaut($params, 3, '*');
 
if(strlen($code_postal) > 2) {
$code_postal = substr($code_postal,0,2);
}
 
$code_pays = $this->affecterValeurParametreOuDefaut($params, 4, 'FR');
return array('lat' => $lat, 'lon' => $lng, 'commune' => $commune,
104,6 → 108,8
$infos_commune_json = @file_get_contents($this->url_service_geo_local."?lat=".$lat."&lon=".$lon);
$infos_commune = json_decode($infos_commune_json);
print_r($infos_commune);
$retour = false;
if ($this->estUnRetourOsmValide($infos_commune)) {