X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/fa30f71a6ab727c90e0b600582f9944dfaa1ca89..76e9012a55abbbe190c2c97d25a17ec87426e687:/search.php diff --git a/search.php b/search.php index e1da846..20c89f8 100644 --- a/search.php +++ b/search.php @@ -1,17 +1,56 @@ $limit) { + shuffle($results); // avoid alphabetical top set + } +} + +if (isset($Place['verbose'])) { + printf("

%s gevonden voor %s:

\n", + $results ? count($results).' resultaten' : 'Niets', + htmlspecialchars($query) + ); +} if (!$results) { - $results = ['index.html']; + print "Niets gevonden."; + return; +} +if (count($results) > $limit) { + array_splice($results, $limit); } -require_once('nieuws.inc.php'); -print '\n";