如何创建Zend服务器上的虚拟主机? [英] How do I create a VirtualHost on Zend Server?

查看:247
本文介绍了如何创建Zend服务器上的虚拟主机?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Zend服务器,我添加了一个虚拟主机到额外的/的httpd-vhosts.conf文件,并从httpd.conf文件中删除#。

I am using zend server and I added one VirtualHost into the extra/httpd-vhosts.conf file and removed # from the httpd.conf file.

这是我加入额外的/的httpd-vhosts.conf文件:

This is what I added into the extra/httpd-vhosts.conf file:

NameVirtualHost *:80

<VirtualHost *:80>
    ServerName quickstart.local
    DocumentRoot D:/quickstart/Code


    <Directory D:/quickstart/Code>
        DirectoryIndex index.php
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>

当我访问quickstart.local它工作正常,但它也影响到本地主机(即当我尝试加载的http://本地主机/ ,我看到同样的网站,我的 HTTP做://quickstart.local/

When I access quickstart.local it is working fine, but it also affects localhost (i.e when I try to load http://localhost/, I see the same site I do for http://quickstart.local/.

我如何解决这个问题?我想这两个本地主机(我用这个另一个项目),并为quickstart.local是独立的。

How do I resolve this issue? I want both localhost (I use this for another project) and quickstart.local to be separate.

推荐答案

我有同样的问题。尝试将主机添加到zend.conf或
添加

I have the same problem. Try to add a host to zend.conf or add

Include conf/extra/httpd-vhosts.conf                   

要htppd.conf

to htppd.conf

这篇关于如何创建Zend服务器上的虚拟主机?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆