X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/6b65b9086b4434c6cc69bf4c8a3f778af5b91115..753d2ac79fab5dab71ab4890fe16916d33decb5c:/lib/template/search-xml.php?ds=sidebyside diff --git a/lib/template/search-xml.php b/lib/template/search-xml.php index bdf1eab5..84e17775 100644 --- a/lib/template/search-xml.php +++ b/lib/template/search-xml.php @@ -50,6 +50,27 @@ } } + if (isset($aResult['asgeojson'])) + { + echo ' geojson=\''; + echo $aResult['asgeojson']; + echo '\''; + } + + if (isset($aResult['assvg'])) + { + echo ' geosvg=\''; + echo $aResult['assvg']; + echo '\''; + } + + if (isset($aResult['astext'])) + { + echo ' geotext=\''; + echo $aResult['astext']; + echo '\''; + } + if (isset($aResult['zoom'])) { echo " zoom='".$aResult['zoom']."'"; @@ -61,14 +82,25 @@ echo " class='".htmlspecialchars($aResult['class'])."'"; echo " type='".htmlspecialchars($aResult['type'])."'"; - if ($aResult['icon']) + if (isset($aResult['icon']) && $aResult['icon']) { echo " icon='".htmlspecialchars($aResult['icon'], ENT_QUOTES)."'"; } - if (isset($aResult['address'])) + if (isset($aResult['address']) || isset($aResult['askml'])) { echo ">"; + } + + if (isset($aResult['askml'])) + { + echo "\n"; + echo $aResult['askml']; + } + + if (isset($aResult['address'])) + { + echo "\n"; foreach($aResult['address'] as $sKey => $sValue) { $sKey = str_replace(' ','_',$sKey); @@ -76,7 +108,10 @@ echo htmlspecialchars($sValue); echo ""; } + } + if (isset($aResult['address']) || isset($aResult['askml'])) + { echo ""; } else