How do I make directories browsable ? How to fix 403 forbidden errors .
How to allow the browsing of directories which do not have index.htm pages
And a common solution for "403 Forbidden" errors...When you access any location on a web server, the serevr expects to serve up the
EXACT named page requested, and if no page name is specified, to show the default page (usually index.htm). If no page is specified, and no index page is found, but other files exist, the server will return a 403 Forbidden Error. To allow an uploaded directory of files to be listed, without having to link to each of them from an index page, then you need to enable Directory Browsing for that directory using the .htaccess file.
Making directories browsable:
- Create a new text file, in a plain text editor (like Notepad or Textpad - do not use Word/Wordpad)
- Enter this line *exactly*:
Options +Indexes- Save the file with the name ".htaccess" (note the leading "." character)
- Upload the file to the directory you wish to make browsable.
Now you have told the webserver (by the .htaccess options Options +Indexes that you want to allow automatic index file creation in that directory.
The automatic index file created will show a list of all the files (if any) that are inside the directory, and any directories below it.
Add to Favourites Print this Article