]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/template/search-xml.php
details view: use class name if type is yes
[nominatim.git] / lib / template / search-xml.php
index aa029d2bb142bcd9fc4b16660e512c4f63063c85..693330bb52cfce29fba95d3ce1c45415085b4b99 100644 (file)
@@ -9,7 +9,7 @@
        echo " timestamp='".date(DATE_RFC822)."'";
        echo " attribution='Data © OpenStreetMap contributors, ODbL 1.0. http://www.openstreetmap.org/copyright'";
        echo " querystring='".htmlspecialchars($sQuery, ENT_QUOTES)."'";
-       if (isset($sViewBox)) echo " viewbox='".htmlspecialchars($sViewBox, ENT_QUOTES)."'";
+       if ($sViewBox) echo " viewbox='".htmlspecialchars($sViewBox, ENT_QUOTES)."'";
        echo " polygon='".($bShowPolygons?'true':'false')."'";
        if (sizeof($aExcludePlaceIDs))
        {
@@ -80,7 +80,8 @@
                echo " display_name='".htmlspecialchars($aResult['name'], ENT_QUOTES)."'";
 
                echo " class='".htmlspecialchars($aResult['class'])."'";
-               echo " type='".htmlspecialchars($aResult['type'])."'";
+               echo " type='".htmlspecialchars($aResult['type'], ENT_QUOTES)."'";
+               echo " importance='".htmlspecialchars($aResult['importance'])."'";
                if (isset($aResult['icon']) && $aResult['icon'])
                {
                        echo " icon='".htmlspecialchars($aResult['icon'], ENT_QUOTES)."'";