-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Welcome to the server-directory-index wiki!
A quote from the official website.
h5ai is a modern file indexer for HTTP web servers with focus on your files. Directories are displayed in a appealing way and browsing them is enhanced by different views, a breadcrumb and a tree overview. Initially h5ai was an acronym for HTML5 Apache Index but now it supports other web servers too.
The initial goal was to share a server in the local network and facilitate quick access to archives and other public files, easily downloadable from any browser, without being forced to connect. The update integrates features from forks of h5ai, with no installation required; just a configuration file. Here are some of the features it improves:
- breadcrumbs
- auto refresh
- custom header and footer for each directory
- select and download multiple files and folders
- filter function for files and folders
- folder size
- localization
- main view, breadcrumb and tree view
- display details
- image preview
- text file preview
- QR codes on hovering files
- thumbnails for images, pdfs and movies
These are some awesome features to improve the web server directory index!
Most options can be customized in config.json, more on that later.
Unpack server directory index h5ai to your /www/*.*
and access your domain/public
Whatever you drop on the Public folder will automatically
be available on the web server and you can easily share the links.
- Download server directory index h5ai
- Open WinSCP or FileZilla or any SFTP client
- Upload the files
If required by your server. Add the following text inside “<Directory /var/www/> ” to redirect every access from outside of the LAN to the /public/ directory.
<Directory /var/www/public/>
DirectoryIndex index.html index.php /_h5ai/server/php/index.php
</Directory>
It will also redirect non existent lookups (i.e domain/unknown_doc will go to /public/)
Change your LAN accordingly!
RewriteEngine On
RewriteCond %{REMOTE_ADDR} !^127\.0.0.1$
RewriteCond %{REMOTE_ADDR} !^XXX\.XXX\.XXX\.(.*)$RewriteCond %{REQUEST_URI} !^/_h5ai(.*)$
RewriteCond %{REQUEST_URI} !^/public(.*)$
RewriteRule $ /public/ [L,R=301]
- copy the _h5ai folder to /var/www/
- try to access domain/_h5ai with a web browser
- you should get a “403 Forbidden” error
Give access to the _h5ai directory to Apache
chmod -R 755 /var/www/_h5ai/
Give write access to the cache folder of _h5ai
needed for some options (thumbs, zip batch download)
chmod o+w /var/www/_h5ai/cache/
Create a symlink to the Public folder.
You can use any other path of your setup.
ln -s /DataVolume/shares/Public/ /var/www/public
Enables the autoindex function of Apache for Directory Listing
a2enmod autoindex
Eestart Apache server to enable customization
/etc/init.d/apache2 restart
You can manage all settings from a single file : /_h5ai/private/conf/options.json
Everything is well documented. For example :
- enable download of multiple files as zip
- enabling QR codes
- and much more
You can edit the file also with Notepad. There’s no need to restart the server between changes!