For an example of what these indexes look like, take a look at the demo.
Alias /icons/ /usr/local/etc/httpd/icons/
You should replace
/usr/local/etc/httpd/ with whatever
you set ServerRoot to be.
Next, you need to tell the server what icons to provide for different types of files. You do this with the AddIcon and AddIconByType directives. We recommend something like the following setup:
AddIconByType (IMG,/icons/image.xbm) image/* AddIconByType (SND,/icons/sound.xbm) audio/* AddIconByType (TXT,/icons/text.xbm) text/*This covers the three main types of files. If you want to add your own icons, simply create the appropriately sized xbm, place it in /icons, and choose a 3-letter ALT identifier for the type.
httpd also requires three special icons, one for directories, one which is a blank icon the same size as the other icons, and one which specifies the parent directory of this index. To use the icons in the distribution, use the following lines in srm.conf:
AddIcon /icons/menu.xbm ^^DIRECTORY^^ AddIcon /icons/blank.xbm ^^BLANKICON^^ AddIcon /icons/back.xbm ..However, not all files fit one of these types. To provide a general icon for any unknown files, use the DefaultIcon directive:
/usr6/rob/public_html/images, use the following line:
AddDescription "My pictures" /usr6/rob/public_html/images/*If you want to have the titles of your HTML documents displayed for their descriptions, use the IndexOptions directive to activate
IndexOptions FancyIndexing ScanHTMLTitlesWARNING: You should only use this option if your server has time to spare!!! This is a costly operation!
IndexIgnore */.??* */README* */HEADER*This tells httpd to ignore any file beginning with ., and any file starting with README or HEADER.
httpd will look for both plaintext and HTML versions of HEADERs or READMEs. If we add the following lines to srm.conf:
ReadmeName README HeaderName HEADERWhen httpd is indexing a directory, it will first look for HEADER.html. If it doesn't find that file, it will look for HEADER. If it finds neither, it will generate its own. If it finds one, it will insert it at the beginning of the index. Similarly, the server will look for README.html, then README to insert a trailer for the document.
Return to the tutorial index