mirror of
https://github.com/osm-search/Nominatim.git
synced 2024-10-27 19:48:44 +03:00
don't print address details if they are not requested
This commit is contained in:
parent
c9d51fe7b8
commit
3abbeb5f08
@ -29,15 +29,17 @@
|
||||
if (isset($aPlace['lon'])) echo ' lon="'.htmlspecialchars($aPlace['lon']).'"';
|
||||
echo ">".htmlspecialchars($aPlace['langaddress'])."</result>";
|
||||
|
||||
echo "<addressparts>";
|
||||
foreach($aAddress as $sKey => $sValue)
|
||||
{
|
||||
$sKey = str_replace(' ','_',$sKey);
|
||||
echo "<$sKey>";
|
||||
echo htmlspecialchars($sValue);
|
||||
echo "</$sKey>";
|
||||
}
|
||||
echo "</addressparts>";
|
||||
if ($bShowAddressDetails) {
|
||||
echo "<addressparts>";
|
||||
foreach($aAddress as $sKey => $sValue)
|
||||
{
|
||||
$sKey = str_replace(' ','_',$sKey);
|
||||
echo "<$sKey>";
|
||||
echo htmlspecialchars($sValue);
|
||||
echo "</$sKey>";
|
||||
}
|
||||
echo "</addressparts>";
|
||||
}
|
||||
}
|
||||
|
||||
echo "</reversegeocode>";
|
||||
|
Loading…
Reference in New Issue
Block a user