]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/lib.php
Merge remote-tracking branch 'upstream/master'
[nominatim.git] / lib / lib.php
index 1517b317102502d75b175ee39949c96af8ce9434..54c8c7d0d7176c581b1e92d5b9d89c3e229f928a 100644 (file)
        {
                $aResult = array(array(join(' ',$aWords)));
                $sFirstToken = '';
-               if ($iDepth < 8) {
+               if ($iDepth < 7) {
                        while(sizeof($aWords) > 1)
                        {
                                $sWord = array_shift($aWords);
                return $iPlaceID;
        }
 
-       function loadStructuredAddressElement(&$aStructuredQuery, &$iMinAddressRank, &$iMaxAddressRank, $aParams, $sKey, $iNewMinAddressRank, $iNewMaxAddressRank)
+       function addQuotes($s)
        {
-               if (!isset($_GET[$sKey])) return false;
-               $sValue = trim($_GET[$sKey]);
-               if (!$sValue) return false;
-               $aStructuredQuery[$sKey] = $sValue;
-               if ($iMinAddressRank == 0 && $iMaxAddressRank == 30)
-               {
-                       $iMinAddressRank = $iNewMinAddressRank;
-                       $iMaxAddressRank = $iNewMaxAddressRank;
-               }
-               return true;
+               return "'".$s."'";
        }