I created a project in zendframework:
zf create project dev.gamenomad.com
Then, I put this:
<VirtualHost *:80>
ServerAdmin webmaster@dummy-host.localhost
DocumentRoot "C:/apache/docs/dev.gamenomad.com/public"
ServerName dev.gamenomad.com
ServerAlias dev.gamenomad.com
ErrorLog "logs/dev.gamenomad.com-error.log"
CustomLog "logs/dev.gamenomad.com-access.log" common
</VirtualHost>
and I put this:
127.0.0.1 dev.gamenomad.com in C:\WINDOWS\system32\drivers\etc
Then, restarted apached..
I get this message when putting this url:
Access forbidden!
You don’t have permission to access the requested directory. There is
either no index document or the directory is read-protected.If you think this is a server error, please contact the webmaster.
Error 403 dev.gamenomad.com 12/11/2011 8:12:29 PM Apache/2.2.17
(Win32) mod_ssl/2.2.17 OpenSSL/0.9.8o PHP/5.3.4 mod_perl/2.0.4
Perl/v5.10.1
Why do I get that error?
You get this error because directory listing isn’t enabled and there’s no default document found.
Add the following code to the VirtualHost to show a list of files in the directory
Or alternatively create a file called
index.html(or any other supported extension which you’ve installed) and put some content into the fileYou may also wish to consider adding the following to the VirtualHost in order to allow access to that directory
Edit in response to the OP’s comment
You already have the following VirtualHost configuration.
ServerAdmin webmaster@dummy-host.localhost
DocumentRoot “C:/apache/docs/dev.gamenomad.com/public”
ServerName dev.gamenomad.com
ServerAlias dev.gamenomad.com
ErrorLog “logs/dev.gamenomad.com-error.log”
CustomLog “logs/dev.gamenomad.com-access.log” common
Changing your configuration to add the
OptionsandAllowsettings you’ll be able to run your website on localhost but it’ll fix your error.