apache如何配置默认的根目录
来源:互联网 发布:2017色情软件app 编辑:程序博客网 时间:2024/04/29 14:34
原文:http://www.cnblogs.com/wangkongming/p/3874219.html
在本地安装了wamp环境,默认的根目录是D:\wamp\www,使用起来非常不方便。那如何改变默认的根目录呢
1,找到httpd.conf文件
D:\wamp\bin\apache\Apache2.2.21\conf
2,找到这个地方
## DocumentRoot: The directory out of which you will serve your# documents. By default, all requests are taken from this directory, but# symbolic links and aliases may be used to point to other locations.##DocumentRoot "d:/wamp/www/"DocumentRoot "D:/webRoot/"
3,修改下面的代码
<Directory "D:/webRoot/"> # # Possible values for the Options directive are "None", "All", # or any combination of: # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews # # Note that "MultiViews" must be named *explicitly* --- "Options All" # doesn't give it to you. # # The Options directive is both complicated and important. Please see # http://httpd.apache.org/docs/2.2/mod/core.html#options # for more information. # Options Indexes FollowSymLinks # # AllowOverride controls what directives may be placed in .htaccess files. # It can be "All", "None", or any combination of the keywords: # Options FileInfo AuthConfig Limit # AllowOverride all # # Controls who can get stuff from this server. ## onlineoffline tag - don't remove Order Deny,Allow Deny from all Allow from 127.0.0.8</Directory>
4,重启apache
5,如果出现403页面,需要把
<Directory "D:/webRoot/"> # # Possible values for the Options directive are "None", "All", # or any combination of: # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews # # Note that "MultiViews" must be named *explicitly* --- "Options All" # doesn't give it to you. # # The Options directive is both complicated and important. Please see # http://httpd.apache.org/docs/2.2/mod/core.html#options # for more information. # Options Indexes FollowSymLinks # # AllowOverride controls what directives may be placed in .htaccess files. # It can be "All", "None", or any combination of the keywords: # Options FileInfo AuthConfig Limit # AllowOverride all # # Controls who can get stuff from this server. ## onlineoffline tag - don't remove #Order Deny,Allow #Deny from all Allow from 127.0.0.8</Directory>
0 0
- apache如何配置默认的根目录
- Apache服务器如何修改默认的文件根目录
- 如何修改apache的文档根目录
- 更改Apache默认网站根目录
- CentOS6修改Apache默认根目录
- ubuntu 下修改apache的默认端口与根目录
- Apache配置网站根目录
- apache配置rewrite后,根目录启用.htaccess,总是跳转到apache默认欢迎页面。
- 兔子-更改 Apache 默认网站根目录
- Tomcat中更改默认端口、更改默认根目录、更改默认页的配置方法
- Apache 根目录修改及虚拟目录、虚拟主机的配置
- 如何设置 Apache HTTP Server 的文件根目录(DocumentRoot)
- 修改vsftpd的默认根目录
- 修改vsftpd的默认根目录
- 修改vsftpd的默认根目录
- TomCat中配置根目录默认页面
- WAMPServer默认配置更改-web根目录
- WAMPServer默认配置更改-web根目录
- js 首页轮换图片
- sipXecs查看已注册用户
- cocos 怎么实现技能状态的cd
- Velt中的目录共享
- 关于句柄和二级指针
- apache如何配置默认的根目录
- C#开发模式
- 第一次敲hdu蟠桃树和第二次的区别
- 我奋斗十八年不是为了和你一起喝咖啡!
- HDU 3605 Escape 最大流
- OpenSSL文档的划分
- Javascript的方法参数是不介意传递多少个参数的!
- VS2013中,为MFC程序创建属性表单
- leetcode-Path Sum II