X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/fe92ec8f17c832c4a663aea399dc90a4c09ce6b1..9bbd31c352bd9bba51508b40bfad9890a46731b9:/nieuws/index.php diff --git a/nieuws/index.php b/nieuws/index.php index b28f72b..51cab26 100644 --- a/nieuws/index.php +++ b/nieuws/index.php @@ -1,9 +1,9 @@ 999) { + $match = "$Page/$year/"; + if (is_numeric($page)) { + $title .= ' '.$monthname[intval($page)]; + $match .= sprintf('%02d-', $page); + } + $title .= ' '.$year; } - else { - $title = "Nieuws vóór 2000"; - $match = "$Page/19??/??"; + elseif ($year === '19') { + $match = "$Page/19??/"; + $title .= " vóór 2000"; } print "

$title

\n\n"; print '
'."\n\n"; - shownews($match, 100); + shownews(glob($match.'*.html')); print "
\n\n"; return 1; } -if ($Args) { - return; -} - print '
'."\n\n"; foreach (array_reverse(glob("$Page/2???")) as $page) { $year = basename($page, '.html'); printf('

%s

'."\n", $page, $year); - printtoc("$page/??"); + printtoc($page); } -if ($pages = glob("$Page/19??/??/*.html")) { - printf('

%s

'."\n", "$Page/oud", 'Eerder'); +if ($pages = glob("$Page/19??/*.html")) { + printf('

%s

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