Apache 配置虚拟目录
来源:互联网 发布:四季优美最大骗局知乎 编辑:程序博客网 时间:2024/05/16 10:56
作者:Lee_ruxing
转自:http://blog.csdn.net/liruxing1715/article/details/7864309
Apache 配置虚拟目录是什么意思呢?
假如您现在的 Apache 配置文件(httpd.conf)中设置的访问路径为:E:/php/web 下,即DocumentRoot "E:/php/web"。哪如何设置一个别的盘符(比如:D盘)下面的一个目录,让 Web 服务器可以去访问呢?就需要配置虚拟目录。
下面为配置步骤:
1、配置虚拟目录就是增加一个节点,找到<IfModule>这块,加入下面的代码;
- # 虚拟目录,访问D盘下面的web目录
- <IfModule dir_module>
- # 设置缺省载入页面
- DirectoryIndex index.html index.htm index.php
- # 设置站点别名,别名与访问路径是相关的,取任何名称都可以(除特殊)
- Alias /myweb "D:/web"
- <Directory D:/web>
- # 设置访问权限
- Order allow,deny
- Allow from all
- </Directory>
- </IfModule>
2、可以把之前的 DocumentRoot 注释掉(也不可);
- #DocumentRoot "E:/php/web"
3、在浏览器中输入:http://localhost/myweb/xx.php 来访问 D:/web 下的文件
- apache配置虚拟目录
- Apache虚拟目录的配置
- Apache虚拟目录的配置
- Apache HttpServer 虚拟目录配置
- apache 2 虚拟目录 配置
- apache中配置虚拟目录
- apache 配置虚拟目录
- Ubuntu 配置Apache虚拟目录
- apache配置虚拟目录
- Apache 配置虚拟目录
- Apache 虚拟目录配置详解
- apache配置虚拟目录
- apache虚拟目录配置
- apache 虚拟目录配置[Ubuntu]
- Apache 配置虚拟目录
- Apache配置虚拟目录
- Ubuntu 配置Apache虚拟目录 .
- 配置apache虚拟目录
- c++实现数据结构九 优先级队列
- 关于Proc中嵌入式SQL的关键字"INDICATOR ”
- 各种语言正则表达式语法比较
- ant使用初步
- 详解iostat -dx 1命令监控IO性能
- Apache 配置虚拟目录
- 字典树,后缀树
- 模式匹配算法
- android ftp listFiles()总是为0
- OpenGL ES相关文件pvr文件、OBJ文件
- Linux 前后台进程切换
- 瀑布流
- JQuery中如何传递参数,如click(),change()等
- Initialization, Provisioning and Management of CMs