From 63bc75b3ddb7fa12ccd3925d64c9bf577a972696 Mon Sep 17 00:00:00 2001 From: Brian Quinion Date: Tue, 3 May 2011 14:22:22 +0000 Subject: [PATCH] enforce limit as maximum number of results --- website/search.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/website/search.php b/website/search.php index 1efb7ff5..cd52d227 100755 --- a/website/search.php +++ b/website/search.php @@ -1167,6 +1167,9 @@ $aClassTypeNameDone[$aResult['osm_type'].$aResult['osm_class'].$aResult['name']] = true; $aSearchResults[] = $aResult; } + + // Absolute limit on number of results + if (sizeof($aSearchResults) >= $iLimit) break; } $sDataDate = $oDB->getOne("select TO_CHAR(lastimportdate - '1 day'::interval,'YYYY/MM/DD') from import_status limit 1"); -- 2.39.5