diff options
author | Theo Chatzimichos <tampakrap@gentoo.org> | 2010-09-15 00:38:51 +0300 |
---|---|---|
committer | Theo Chatzimichos <tampakrap@gentoo.org> | 2010-09-15 00:38:51 +0300 |
commit | e967b03e750b074c0bf9099922aab9dce1870d32 (patch) | |
tree | 24d8a28323fbd9694367be09997fea2f1a4151ab | |
parent | update-venus: Fix path for htdocs (diff) | |
download | planet-e967b03e750b074c0bf9099922aab9dce1870d32.tar.gz planet-e967b03e750b074c0bf9099922aab9dce1870d32.tar.bz2 planet-e967b03e750b074c0bf9099922aab9dce1870d32.zip |
Archive files are rearranged in dirs based on year, change index.php to
reflect this change. Patch by my brother :)
-rw-r--r-- | archives/planet/index.php | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/archives/planet/index.php b/archives/planet/index.php index 3dcde8b..0083a61 100644 --- a/archives/planet/index.php +++ b/archives/planet/index.php @@ -62,16 +62,18 @@ <? $scandir = scandir('./', 1); - $scandir = preg_grep('/html$/', $scandir); - - echo "<ul>\n"; - foreach($scandir as $filename) { - echo "<li> <a href='$filename'>$filename</a></li>\n"; + echo "<ul>"; + foreach ($scandir as $curdir) { + if ( $curdir == "index.php" || $curdir == ".." || $curdir == "." ) continue; + $cscan = scandir('./' . $curdir, 1); + foreach($cscan as $filename) { + if ( $filename == "." || $filename == ".." ) continue; + echo "<li> <a href='$filename'>$filename</a></li>\n"; + } } echo "</ul>"; ?> - </td></tr> |