Directory Auto Index

Ours web servers are configured by default to not display the list of files contained in directories. This is a security measure, because the directory may contain files that are not normally exposed through links on the web site.

But some times you need an easy way to simple list and link the files inside a specific directory tree, like this picture.

directory_listing

To enable the directory Auto Index (or auto listing) feature, create a file named .htaccess inside the directory you want it, with this content:

Options +Indexes

 

All directory tree below this file will also have this feature enabled, until another .htaccess disable it again.