]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/Geocode.php
Merge remote-tracking branch 'upstream/master'
[nominatim.git] / lib / Geocode.php
index a9fa44fe0578976c9f77b45e491ae7dd5b073fa3..c1fae0bbec399305b1efcbccc02b41e3e9f43163 100644 (file)
                        $fRight = (float)$sRight;
                        $fTop = (float)$sTop;
                        $fBottom = (float)$sBottom;
                        $fRight = (float)$sRight;
                        $fTop = (float)$sTop;
                        $fBottom = (float)$sBottom;
-                       if ($fRight > $fLeft && $fBottom > $fTop
-                           && ($fRight - $fLeft) < 2 && ($fBottom - $fTop) < 2)
+                       if ($fRight > $fLeft && $fBottom < $fTop
+                           && ($fRight - $fLeft) < 2 && ($fTop - $fBottom) < 2)
                                $this->aViewBox = array($fLeft, $fBottom, $fRight, $fTop);
                }
 
                                $this->aViewBox = array($fLeft, $fBottom, $fRight, $fTop);
                }
 
                                                        $aPointPolygon['minlon'] = $aPointPolygon['minlon'] - $fRadius;
                                                        $aPointPolygon['maxlon'] = $aPointPolygon['maxlon'] + $fRadius;
                                                }
                                                        $aPointPolygon['minlon'] = $aPointPolygon['minlon'] - $fRadius;
                                                        $aPointPolygon['maxlon'] = $aPointPolygon['maxlon'] + $fRadius;
                                                }
-                                               $aResult['aBoundingBox'] = array($aPointPolygon['minlat'],$aPointPolygon['maxlat'],$aPointPolygon['minlon'],$aPointPolygon['maxlon']);
+                                               $aResult['aBoundingBox'] = array((string)$aPointPolygon['minlat'],(string)$aPointPolygon['maxlat'],(string)$aPointPolygon['minlon'],(string)$aPointPolygon['maxlon']);
                                        }
                                }
 
                                        }
                                }