]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/Geocode.php
make sure Illinois,Alabama,Louisiana state code special handling is case insensitive
[nominatim.git] / lib / Geocode.php
index 6c5fb23e2c3c4cd8d9f2e3d7ae460dbc1ee54190..b2eee7ba6b927162e6466c8045c23d85b2ca0b12 100644 (file)
@@ -535,9 +535,9 @@ class Geocode
 
         // Conflicts between US state abreviations and various words for 'the' in different languages
         if (isset($this->aLangPrefOrder['name:en'])) {
-            $sQuery = preg_replace('/(^|,)\s*il\s*(,|$)/', '\1illinois\2', $sQuery);
-            $sQuery = preg_replace('/(^|,)\s*al\s*(,|$)/', '\1alabama\2', $sQuery);
-            $sQuery = preg_replace('/(^|,)\s*la\s*(,|$)/', '\1louisiana\2', $sQuery);
+            $sQuery = preg_replace('/(^|,)\s*il\s*(,|$)/i', '\1illinois\2', $sQuery);
+            $sQuery = preg_replace('/(^|,)\s*al\s*(,|$)/i', '\1alabama\2', $sQuery);
+            $sQuery = preg_replace('/(^|,)\s*la\s*(,|$)/i', '\1louisiana\2', $sQuery);
         }
 
         // Do we have anything that looks like a lat/lon pair?