网络营销电子商务研究中心  
How to buy the best prescription safety glasses in Canada? Let's study!
Go Back   网络营销电子商务研究中心 > 休闲娱乐 > 网络资源
User Name
Password
 
FAQ Members List Calendar Cheap Glasses

Reply
 
Thread Tools Display Modes
  #1   IP: 114.238.104.195
Old 2012-09-30, 11:10 AM
topvip topvip is offline
超级版主
 
Join Date: 2006-01-04
Posts: 1206
topvip 正向着好的方向发展
Default Disable directory listings

Preventing directory listings can be very useful if for example, you have a directory containing important '.zip' archive files or to prevent viewing of your image directories. Alternatively it can also be useful to enable directory listings if they are not available on your server, for example if you wish to display directory listings of your important '.zip' files.

To prevent directory listings, create a .htaccess file following the main instructions and guidance which includes the following text:


htaccess-guide.com/disable-directory-listings/






IndexIgnore *



The above lines tell the Apache Web Server to prevent directory listings of directories and files within the directory containing the .htaccess file. The '*' represents a wildcard, this means it will not display any files. It is possible to prevent listings of only certain file types, so for example you can show listings of '.html' files but not your '.zip' files.

To prevent listing '.zip' files, create a .htaccess file following the main instructions and guidance which includes the following text:









IndexIgnore *.zip



The above line tells the Apache Web Server to list all files except those that end with '.zip'.

To prevent listing multiple file types, create a .htaccess file following the main instructions and guidance which includes the following text:









IndexIgnore *.zip *.jpg *.gif



The above line tells the Apache Web Server to list all files except those that end with '.zip', '.jpg' or '.gif'.

Alternatively, if your server does not allow directory listings and you would like to enable them, create a .htaccess file following the main instructions and guidance which includes the following text:









Options +Indexes



The above line tells the Apache Web Server to enable directory listing within the directory containing this .htaccess file. You can also reverse this to disable directory listings by replacing the plus sign before the text 'Indexes' with a minus sign. e.g. 'Options -Indexes'.

You can also include a default description for the directory listings that is displayed at the top of the page by placing a file called 'HEADER' in the same directory. The contents of this file are displayed before the list of directory contents. You can also include a footer, by creating a file called 'README'. The contents of this file are displayed after the list of directory contents.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 2 (0 members and 2 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Becoming an editor at the Open Directory yahoo 闲话灌水 0 2009-05-24 01:08 PM
PR6 Web Directory List car Web Directory 0 2007-11-01 02:18 PM
What are the Strongest Directories? smiling 网站链接开发 1 2007-07-28 09:26 PM
Directory Title (site sift) topvip Web Directory 0 2007-06-06 10:26 AM
10 Tips to a More Profitable Directory sunshine Web Directory 0 2007-05-09 08:37 PM

Prescription-glasses.com offers prescription glasses online at discount prices.
All times are GMT +8. The time now is 08:56 AM.


Powered by vBulletin Version 3.8.7
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.