Miscellaneous > Programming & Networking

Apache autoindexer

<< < (2/3) > >>

Master of Reality:
huh?

beltorak0:
You mean the header that is displayed whenever you view a directory?  It's a file, notmally HEADER that is in the directory.

from that apache link I gave you:
Apache Docs (1.3)
 
quote:
HeaderName  directive
Syntax: HeaderName filename
Context: server config, virtual host, directory, .htaccess
Override: Indexes
Status: Base
Module: mod_autoindex
Compatibility: some features only available after 1.3.6; see text

The HeaderName directive sets the name of the file that will be inserted at the top of the index listing. Filename is the name of the file to include.

    Apache 1.3.6 and earlier: The module first attempts to include filename.html as an HTML document, otherwise it will try to include filename as plain text. Filename is treated as a filesystem path relative to the directory being indexed. In no case is SSI processing done. Example:

        HeaderName HEADER

    when indexing the directory /web, the server will first look for the HTML file /web/HEADER.html and include it if found, otherwise it will include the plain text file /web/HEADER, if it exists.


--- End quote ---


read som other stuff there (like IndexIgnore, ReadmeName, etc etc).

-t.

Kintaro:
cool

voidmain:
I use "HEADER.html" and "README.html" to modify the beginning and end of the HTML generated by mod_autoindex. If you want an example see http://voidmain.kicks-ass.net/files/HEADER.html and http://voidmain.kicks-ass.net/files/README.html so when you view http://voidmain.kicks-ass.net/files/ it shows up the way I want it.

You can also manipulate the columns using key words in your httpd.conf:

IndexOptions FancyIndexing HTMLTable SuppressHTMLPreamble VersionSort NameWidth=* DescriptionWidth=* SuppressLastModified

You might want to look at the documentation for mod_autoindex at www.apache.org.

I also slightly changed the source code for mod_autoindex. It was spitting out HTML that I believe was wrong so I fixed it to pass HTML 4.01.

[ January 04, 2003: Message edited by: void main ]

Kintaro:
Thanks VoidMain.

You have a PM that i sent a while ago btw.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version