Home
Softono

Nginx Pretty Index

Open source XSLT
11
Stars
3
Forks
0
Issues
1
Watchers
5 years
Last Commit

 About Nginx Pretty Index

Generate Beautiful AutoIndex page for Nginx using XML and XSLT

Platforms

Web Self-hosted

Languages

XSLT

Need Help Installing Nginx Pretty Index?

We provide expert installation service for this software. Our team will install, configure, and secure Nginx Pretty Index on your server. plans start at just $30.

Nginx Pretty Index

View on GitHub

nginx-pretty-index

XSLT styles for Nginx AutoIndex Pages

pretty nginx autoindex

Installation

  • install nginx

  • install ngx_http_xslt_module. on Ubuntu, it's named as nginx-module-xslt

  • load modules in nginx.conf

    load_module modules/ngx_http_xslt_filter_module.so;
    
  • download styles.xslt

  • modify server blocks as required. here's a snippet for your reference

    server {
      ......
      ......
    
      location / {
        try_files $uri @autoindex;
      }
    
      location @autoindex {
        autoindex on;
        autoindex_exact_size off;
        autoindex_format xml;
    
        xslt_string_param path $uri;
        xslt_stylesheet path/to/styles.xslt;
      }
    
      ......
      ......
    
    }
    
  • check nginx syntax (sudo nginx -t) and restart nginx process

Features

  1. Beautiful Colors (borrowed from Keith Knittel - CSSTricks)
  2. Responsive Page - Mobile users can browse through files easily
  3. Filter files by name
  4. Icons - File and Folder icons

Credits

This work is based upon dirlist.xslt by Moritz Wilhelmy