mirror of
https://github.com/osm-search/Nominatim.git
synced 2024-09-20 15:37:49 +03:00
sMoreURL now includes countrycodes values
This commit is contained in:
parent
3ff8bb55a7
commit
adb6ea546f
@ -126,6 +126,12 @@ class Geocode
|
||||
return $this->aExcludePlaceIDs;
|
||||
}
|
||||
|
||||
|
||||
public function getCountryCodes()
|
||||
{
|
||||
return $this->aCountryCodes;
|
||||
}
|
||||
|
||||
public function getViewBoxString()
|
||||
{
|
||||
if (!$this->aViewBox) return null;
|
||||
|
@ -110,6 +110,7 @@ if ($bShowPolygons) $sMoreURL .= '&polygon=1';
|
||||
if ($oGeocode->getIncludeAddressDetails()) $sMoreURL .= '&addressdetails=1';
|
||||
if ($oGeocode->getIncludeExtraTags()) $sMoreURL .= '&extratags=1';
|
||||
if ($oGeocode->getIncludeNameDetails()) $sMoreURL .= '&namedetails=1';
|
||||
if ($oGeocode->getCountryCodes()) $sMoreURL .= '&countrycodes='.join(',', $oGeocode->getCountryCodes());
|
||||
if ($sViewBox) $sMoreURL .= '&viewbox='.urlencode($sViewBox);
|
||||
if (isset($_GET['nearlat']) && isset($_GET['nearlon'])) $sMoreURL .= '&nearlat='.(float)$_GET['nearlat'].'&nearlon='.(float)$_GET['nearlon'];
|
||||
$sMoreURL .= '&q='.urlencode($sQuery);
|
||||
|
Loading…
Reference in New Issue
Block a user