Article Diary - General Knowledge Digest

How to protect specific folder or disable directory browsing using htaccess?

Use the following htaccess code to protect a specific folder on your website or disabling directory browsing. This is useful if your folder doesn’t have a default index page and all files within that directory can be easily seen and downloaded by visitors. It is particularly useful if you are selling digital downloads such as zip files in a directory. To avoid that use the following code in the .htaccess file.
# disable directory browsing

Options All -Indexes
Attached Files
There are no attachments for this article.
Comments
There are no comments for this article. Be the first to post a comment.
Name
Email
Security Code Security Code
Related Articles RSS Feed
PHP Questions for Interview with Answers
Viewed 1750 times since Wed, Feb 24, 2010
Google Maps jQuery Plugin
Viewed 1370 times since Thu, Jan 7, 2010
Review of Mobile Web Application Frameworks
Viewed 1768 times since Mon, May 9, 2011
8 Basics of Regular Expressions
Viewed 1254 times since Mon, Mar 8, 2010
Create Dynamic Tabs with jQuery
Viewed 1270 times since Sat, Feb 6, 2010
How do I setup and use SSH?
Viewed 1958 times since Thu, Oct 15, 2009
What is rel="nofollow" attribute?
Viewed 1059 times since Thu, May 13, 2010
30 High Quality Charts & Graphs for Web Developers
Viewed 3686 times since Wed, Mar 23, 2011
Flash Webcam Image Capture
Viewed 1964 times since Thu, Nov 12, 2009
jCart - Free PHP AJAX Shopping Cart
Viewed 1728 times since Sun, Jan 3, 2010
MENU