Download (v1.1, sept 1 2009)
Apache’s default directory index pages are ugly. Indices is a set of hacks that makes them pretty, and more usable.
What it does
- Simple, clean design
- Easily customizable logo and link at the top
- Optional readme.html file inserted before file list
- Long filenames are visible
- Directory names in bold; trailing slashes stripped from directory names
- Nice file icons
- Output is XHTML 1.0 Strict, styled with CSS
- Should be easy to modify for your own needs
How it works
Unlike other PHP-based solutions, Indices is based on Apache’s built-in directory mechanism, so it’s pretty easy to seamlessly integrate it into your entire website.
Indices uses a few helpful Apache
If you’re curious about the plumbing, read this blog post.
I developed Indices for my web server, which runs Apache 2.0.x and PHP 5.1.x. It’ll probably require some tweaking to get it working with earlier versions of either.
If you’re running Apache 1, you’ll be able to use some of this code for inspiration, but you’ll need to do a lot more hackery.