Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

.htaccess problem / Directory browsing

Status
Not open for further replies.

abovebrd

IS-IT--Management
May 9, 2000
690
US
Can some point me to some useful info related to .htaccess files.

I am specifically looking for the syntax related to changing the default behaivor of directroy browsing. It seems that directory browsing is enabled by default. Someone once told me that this behavior can be modifed using an .htaccess file.

My goal is to prvent directory browsing sever wide. Currently I have to add a blank index.html file to prevent this.

Any suggestions ?

-Danny






 
In the directories where you don't want indexing, look for Options in that directory's directory container and delete the Indexes option. Having an "index.html" file in all your directories is still a good idea though. It's a little added security, just in case. You can put a message in there or a redirect script.

"Now go do the right thing"
 
abovebrd,

In your httpd.conf file, look for the following line (or similar):

Options Indexes FollowSymLinks

and change it to:

Options FollowSymLinks

thus, getting rid of the Indexes option - server-wide.


I HATE BEING A NEWBIE!
-grumpy smurf
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top