]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/lib.php
make HTML validator happy with details page
[nominatim.git] / lib / lib.php
index 6fdc45a052c704714f3f399b4458e8822a20c50b..268c75581f4292940fcc914ea0855d7849d0e68d 100644 (file)
 
                if (sizeof($aNearPostcodes))
                {
-                       return array(array('lat' => $aNearPostcodes[0]['lat'], 'lon' => $aNearPostcodes[0]['lon'], 'radius' => 0.005));
+                       $aPostcodes = array();
+                       foreach($aNearPostcodes as $aPostcode)
+                       {
+                               $aPostcodes[] = array('lat' => $aPostcode['lat'], 'lon' => $aPostcode['lon'], 'radius' => 0.005);
+                       }
+
+                       return $aPostcodes;
                }
 
                return false;