指定过去没有效果,非得用这方式才行 <!-- <br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> -->DocumentRoot " D:/Tweb/hooyes/webroot " (E:/phpwork)# # This should be changed to whatever you set DocumentRoot to. # <Directory " E:/phpwork" > (这个地方也要修改)不知道是我那里配的不对,如果一定要这样的话,搞2个以上站点不是很麻烦了? 谢谢指教
指定过去没有效果,无法找到该页,非得用这方式才行 <!-- <br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> -->DocumentRoot " E:/phpwork" # # This should be changed to whatever you set DocumentRoot to. # <Directory " E:/phpwork" > (这个地方也要修改)不知道是我那里配的不对,如果一定要这样的话,搞2个以上站点不是很麻烦了? 谢谢指教
<!-- <br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> -->DocumentRoot " D:/Tweb/hooyes/webroot " (E:/phpwork)#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory " E:/phpwork" > (这个地方也要修改)不知道是我那里配的不对,如果一定要这样的话,搞2个以上站点不是很麻烦了?
谢谢指教
<!-- <br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> -->DocumentRoot " E:/phpwork" #
# This should be changed to whatever you set DocumentRoot to.
#
<Directory " E:/phpwork" > (这个地方也要修改)不知道是我那里配的不对,如果一定要这样的话,搞2个以上站点不是很麻烦了?
谢谢指教
DocumentRoot "E:\phpwork"
</VirtualHost>你的这个是在哪个文件中配置的,全名
DocumentRoot "E:\phpwork"
<Directory " E:/phpwork" >这个是主机下的虚拟目录</Directory>
</VirtualHost>
我现在怀疑这版本是不是不支持这样的方法?
猜的
NameVirtualHost 命令设置了吗?
DocumentRoot "E:/phpWork/"
ServerAdmin admin@localhost
ServerName www.xxx.com
ServerAlias xxx.comxxxxx
NameVirtualHost *:443 如果需要 https 把这个也加上.
讲apache 中conf/httpd.conf文件中
#Include conf/extra/httpd-vhosts.conf
这句前面的"#"去掉
然后在
conf/extra/httpd-vhosts.conf 文件中 添加下面的内容
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "D:/www/mall/upload"
ServerName ecmall
ErrorLog "logs/localhost-error.log"
CustomLog "logs/localhost-access.log" common
</VirtualHost>其中DocumentRoot 后面跟的时候你项目的绝对路径
ServerName 跟的是用哪个 域名访问