Page 1 of 1

local vhosts

Posted: Sun May 16, 2010 12:50 am
by Torniquet
Been at this for hours and i am stuck ¬¬

Here is what i have in my httpd-vhosts.conf file.

Code: Select all

NameVirtualHost *:80


<VirtualHost *:80>
	DocumentRoot "C:/Xampp/xampp/htdocs"
	ServerName localhost
</VirtualHost>

<VirtualHost *:80>
	DocumentRoot "D:/webserver/test"
	ServerName test.localhost

	<Directory "D:/webserver/test">
		Options Indexes FollowSymLinks Includes ExecCGI
		AllowOverride All
		Order allow,deny
		Allow from all
	</Directory>
</VirtualHost>
i have added all the bits into the windows hosts file aswell.

restarted both computer and xampp several times.

and all i seem to be getting is the following...

Code: Select all

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
test.localhost
16/05/2010 01:15:42
Apache/2.2.14 (Win32) DAV/2 mod_ssl/2.2.14 OpenSSL/0.9.8l mod_autoindex_color PHP/5.3.1 mod_apreq2-20090110/2.7.1 mod_perl/2.0.4 Perl/v5.10.1 
anyone give me some idea on how to fix this prob?

i have checked the folders... and all is right... there is index files, none are read protected. its just being a pain in the backside.

Re: local vhosts

Posted: Sun May 16, 2010 9:53 pm
by Torniquet
ok i have it sorted now...

incase anyone is interested

this is how i have mine layed out.

Code: Select all

NameVirtualHost 127.0.0.1:80


<VirtualHost 127.0.0.1:80>
	ServerAdmin you@localhost
	DocumentRoot "C:/Xampp/xampp/htdocs"
	ServerName localhost:80
	ErrorLog logs/localhost-error_log
	CustomLog logs/localhost-access_log combined
</VirtualHost>

<VirtualHost 127.0.0.1:80>
	ServerAdmin you@virtualdomain
	DocumentRoot D:\WebServer\test
	ServerName trialsite:80
	ServerAlias trialsite
	ErrorLog logs/trialsite-error_log
	CustomLog logs/trialsite-access_log combined

	<Directory "D:\WebServer\test">
		Options Indexes FollowSymLinks Includes ExecCGI
		AllowOverride All
		Order allow,deny
		Allow from all
	</Directory>
</VirtualHost>