我在Windows 7上运行Zend Server
以下是我采取的步骤......
更改文档根文件夹:
# This should be changed to whatever you set DocumentRoot to.
<Directory "D:/Webs">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
在块中添加以下行:
Alias /lib "D:/Webs/Base/lib/"
打开conf \ extra \ httpd-vhosts.conf文件。 取消注释这一行:
NameVirtualHost *:80
添加以下内容:
<VirtualHost *:80>
ServerName localhost
DocumentRoot "D:/Webs"
</VirtualHost>
<VirtualHost *:80>
ServerName lib.localhost
DocumentRoot "D:/Webs/Base/lib"
</VirtualHost>
如果我只是添加第一个条目,那么Apache就可以了,但是如果我在“D:/ Webs”路径中添加更多内容,那么就无法启动Apache。