Apache HTTP Server > httpd.conf

来源:互联网 发布:mac 删除苹果系统 编辑:程序博客网 时间:2024/05/20 17:07

<IfModule dir_module>
    DirectoryIndex index.html index.php
</IfModule>

访问服务器的某个目录 , 例如 : HTTP://localhost/Test/test

如果目录下有配置的这些文件(例如 : 上面配置的index.html , index.php) , 则默认访问这些文件 .

如果没有 , 则会有两种情况 :

1 . Directory标签中存在Indexes字符串时 , 则用户可以访问目录结构 .

2 . Directory标签中不存在Indexes字符串时 , 则返回403错误 .


<Directory "">

  Options Indexes FollowSymLinks

</Directory>

当去掉Indexes时 , 用户无法访问目录结构 .-

0 0