X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/ba6c22ab7c2f350603f3c1510be7ead7ddbadc3a..212c5051484f6ee08b95f284c133337896c42f41:/nieuws/index.php diff --git a/nieuws/index.php b/nieuws/index.php index 25efd2d..cf57dbc 100644 --- a/nieuws/index.php +++ b/nieuws/index.php @@ -5,14 +5,14 @@ include 'nieuws.inc.php'; if ($page and !is_numeric($page)) { $edit = !empty($User['admin']) ? htmlspecialchars(@$_GET['edit']) : NULL; - print shownewsarticle($Args, FALSE, $edit); + print shownewsarticle($Page.$Args, FALSE, $edit); return 1; } if ($year) { ob_clean(); $title = "Nieuws"; - if (is_numeric($year)) { + if (is_numeric($year) and $year > 999) { $match = "$Page/$year/"; if (is_numeric($page)) { $title .= ' '.$monthname[intval($page)]; @@ -20,22 +20,16 @@ if ($year) { } $title .= ' '.$year; } - else { + elseif ($year === '19') { $match = "$Page/19??/"; $title .= " vóór 2000"; } print "

$title

\n\n"; - print '
'."\n\n"; shownews(glob($match.'*.html')); - print "
\n\n"; return 1; } -if ($Args) { - return; -} - print '
'."\n\n"; foreach (array_reverse(glob("$Page/2???")) as $page) { @@ -45,7 +39,7 @@ foreach (array_reverse(glob("$Page/2???")) as $page) { } if ($pages = glob("$Page/19??/*.html")) { - printf('

%s

'."\n", "$Page/oud", 'Eerder'); + printf('

%s

'."\n", "$Page/19", 'Eerder'); printtoc($pages); }