我是PHP初学者,请教高手。我安装了Apache+PHP+MySQL+Serv-U 服务器套件 1.0 ,安装在 F:\Apache+MySQL+PHP文件夹下。默认访问文件路径是: F:\Apache+MySQL+PHP\MyServer\Apache2.2.9\htdocs这样很不方便,我想把文件放在 E:\WebSite\htdocs文件夹下来访问。那么我该如何修改配置文件?先谢啦!
调试欢乐多
#2 在apache/extra/httpd-vhosts.conf添加虚拟目录;
<VirtualHost *:80>
DocumentRoot "虚拟目录"
ServerName 域名
<Directory "虚拟目录">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#3 在C:/Windows/System32/drivers/etc/hosts把你的域名加进来。
形式:127.0.0.1 你的域名
②在httpd-vhosts.conf中修改:
<VirtualHost *:8080>
ServerAdmin [email protected]
DocumentRoot "F:/abc"
ServerName 127.0.0.1
ErrorLog "logs/dummy-host2.huyinglong.com-error.log"
CustomLog "logs/dummy-host2.huyinglong.com-access.log" common
</VirtualHost>
<Directory "F:/abc">
Options Indexes Includes FollowSymLinks
AllowOverride None
Order deny,allow
Allow from all
</Directory>
③访问http://127.0.0.1:8080