diff --git a/README.rst b/README.rst index 67a28e0..ad6f1c5 100644 --- a/README.rst +++ b/README.rst @@ -1,9 +1,24 @@ -========================= -Nginx_ Fancy Index module -========================= +======================== +Nginx Fancy Index module +======================== .. contents:: +The Fancy Index module makes possible the generation of file listings, like +the built-in `autoindex `__ +module does, but adding a touch of style. This is possible because the module +module allows a certain degree of customization of the generated content: + +* Custom headers. Either local or stored remotely (*working*). +* Custom footers. Either local or stored remotely (*working*). +* Insert readme files either at the top or the bottom of listings + (*partially working*). +* Add you own CSS style rules (*not yet implemented*). + +This module is designed to work with Nginx_, a high performance open source web +server written by `Igor Sysoev `__. + + Requirements ============ * Sources for Nginx_ 0.6.x, and its requirements. @@ -40,6 +55,18 @@ Building 5. Configure Nginx_ by using the modules' configuration directives_. +Example +======= + +You can test the default built-in style by adding the following lines into +a ``server`` section in your Nginx_ configuration file:: + + location / { + fancyindex on; # Enable fancy indexes. + fancyindex_exact_size off; # Output human-readable file sizes. + } + + Directives ========== diff --git a/template.h b/template.h index 841fcc1..62e006b 100644 --- a/template.h +++ b/template.h @@ -45,6 +45,7 @@ static const u_char t01_head1[] = "" "" "\n" "" "\n" "Index of " diff --git a/template.html b/template.html index f9e28f5..226e5de 100644 --- a/template.html +++ b/template.html @@ -44,6 +44,7 @@ </style> <script type="text/javascript"> + // <![CDATA[ function ngx_onload(){ var f=document.getElementById('readme'); if(!(f&&f.contentDocument))return; @@ -51,6 +52,7 @@ f.contentDocument.body.style.padding='0'; f.contentDocument.body.style.margin='0'; } + // ]]> </script> <title>Index of