Apache新版配置虚拟主机的注意事项
2016-04-18 11:54
405 查看
原文链接:https://www.geek-share.com/detail/2671951642.html
1.关于没有默认索引文件(index.php或者index.html)时,列出目录:需要开启模块
LoadModule autoindex_module modules/mod_autoindex.so
且配合httpd-vhosts.conf的设置:
<Directory "E:/www/demo"> Options Indexes FollowSymLinks # for rewrite AllowOverride Indexes FileInfo </Directory>
Indexes 即: 如果输入的网址对应服务器上的一个文件目录,而此目录中又没有DirectoryIndex指令(例如:DirectoryIndex index.html index.php),那么服务器会返回由mod_autoindex模块生成的一个格式化后的目录列表
2.关于权限变为:Require all granted
<VirtualHost *:8081> ServerName www.smartmall.com DocumentRoot "D:/website/www.smartmall.com/frontend/web" <Directory "D:/website/www.smartmall.com/frontend/web"> Options Indexes FollowSymLinks Require all granted AllowOverride All </Directory> </VirtualHost>
其中:AllowOverride All 是支持rewrite重写,需要开启httpd.conf中的 LoadModule rewrite_module modules/mod_rewrite.so
转载于:https://www.cnblogs.com/intval/p/5403888.html
相关文章推荐
- Apache新版配置虚拟主机的注意事项
- PHP中级篇 Apache配置httpd-vhosts虚拟主机总结及注意事项
- PHP中级篇 Apache配置httpd-vhosts虚拟主机总结及注意事项[OK]
- PHP中级篇 Apache配置httpd-vhosts虚拟主机总结及注意事项[OK]
- Apache配置httpd-vhosts虚拟主机总结及注意事项
- PHP中级篇 Apache配置httpd-vhosts虚拟主机总结及注意事项[OK]
- PHP中级篇:Apache配置httpd-vhosts虚拟主机总结及注意事项【OK】
- Apache 配置httpd-vhosts虚拟主机总结及注意事项
- Apache配置httpd-vhosts虚拟主机总结及注意事项
- PHP中级篇 Apache配置httpd-vhosts虚拟主机总结及注意事项(转载)
- Apache 配置httpd-vhosts虚拟主机总结及注意事项
- apache虚拟主机安装注意事项
- apache虚拟主机安装注意事项
- nginx 配置多虚拟主机需要注意事项
- 基于域名虚拟主机配置注意事项
- apache中伪静态配置和使用(Apache虚拟主机下Discuz伪静态)
- zz Apache 虚拟主机 VirtualHost 配置
- 在linux下配合apache和resin配置多IP的虚拟主机
- Apache虚拟目录和多端口多主机名配置