Skip to main content.
August 17th, 2005

Disable or Enable Directory Browsing or Indexing

Browsing or indexing is an option that allows the contents of a directory to be displayed in the browser when the directory does not contain an index page or default page.

For example, if you make an http call to a directory such as http://yourdomain.com/files/, it would list all the files in that directory without the need for an html page with links.

We will need to create a blank file called “.htaccess”. You can name it “htaccess.txt” while your editing it, then rename the file to “.htaccess” after the file is on your web server, and upload it in your site root.

To Disable Directory Browsing or Indexing

Type or copy and past the following line of text in to your blank file.
the word “All” for every folder in that directory follows the same rule.

Options All -Indexes

Enable Directory Browsing or Indexing

You can reactivate it by adding the following line to your .htaccess file:


Options +Indexes

Once this is added, the directory will fully index again.

Posted by Dablu in htaccess Tutorials

This entry was posted on Wednesday, August 17th, 2005 at 6:24 am and is filed under htaccess Tutorials. You can follow any responses to this entry through the comments RSS 2.0 feed. You can leave a response, or trackback from your own site.

2 Responses to “Disable or Enable Directory Browsing or Indexing”

  1. full house in poker says:

    bonuscode full tilt

    1234

  2. Anonymous says:

    penis enlargement device

    penis enlargement product penis enlargement device penis enlargement device

Leave a Reply

You must be logged in to post a comment.