I am having trouble getting a virtual server up and running with ZEND. I have followed the installer and set up a project in my C:/ drive. However, the browser will not pick up the site.
I changed the appache config file to uncomment the following line.
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
I changed the vhosts.conf file with the following code based on the quickstart information included on the zend website. The project folders are located at C:\zendProject\quickstart\public
<VirtualHost *:8080>
ServerName local
DocumentRoot /zendProject/quickstart/public
SetEnv APPLICATION_ENV "development"
<Directory /zendProject/quickstart/public>
DirectoryIndex index.php
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
I then changed the hosts file to read with the following lines.
127.0.0.1 localhost
127.0.0.1 local
::1 localhost
I then restarted the appache server using the vista services manager. I checked the basic webpage for the ZEND control panel and this is working so the server is definately operational, but I get a message saying that the browser cannot connect to local.
Does anyone know what I am doing wrong?
I just looked through the error logs and found the following entry – not sure if this helps
[Sun Aug 19 12:05:38 2012] [warn] NameVirtualHost *:8080 has no VirtualHosts
you can pretty much use any port you want with a vhost just make sure you have a line like:
NameVirtualHost *:80somewhere in the vhost document. This line specifies the port apache looks at for routing. Most of the prebuilt servers (WAMP, Xampp, Zend Server) will come with a templatehttpd-vhosts.confthat usually includses this line. Sometimes it is still commented, either way make sure it is there and uncommented and reflects the port you want to use.Also if you are using Zend Framework MVC projects in a vhost you want to FollowSymlinks
Here is complete example of a working httpd-vhosts.conf:
This is the httpd-vhosts.conf provided Zend Server CE as modified for my dev environment.
A few more notes.
LoadModule rewrite_module modules/mod_rewrite.so