Problem configuring virtual host
Posted by: zagadka (---.cpe.webspeed.dk)
Date: October 16, 2014 07:48PM

Version of Operating system? - Windows 7 x64
Version of Wamp Server installed? - Wamp Server 2.5 64 bit
Version of Apache you are running? - 2.4.9 (default)
Version of MySQL you are running? - 5.5.12 (default)
Version of PHP you are running? - 5.6.17 (default)

What colour is your WampManager icon? ( the in the system tray )
It could be Green, Orange or Red - Green (otherwise I wouldn't ask)

Do you have a HOSTS file? - Yes, not the answer you're looking for, but answers the question. You are looking for the content of the file.
127.0.0.1 localhost
::1 localhost

127.0.0.1 soborghave
::1 soborghave

I have defined two virtual hosts (one for localhost and one for my project "soborghave"winking smiley as follows:
<VirtualHost *:80>
DocumentRoot "e:/wamp/www"
ServerName localhost
ServerAlias localhost
<Directory "e:/wamp/www">
AllowOverride All
Require local
</Directory>
</VirtualHost>

<VirtualHost *:80>
DocumentRoot "e:/wamp/www/soborghave"
ServerName soborghave
<Directory "e:/wamp/www/soborghave">
AllowOverride All
Require local
</Directory>
</VirtualHost>

I have included the virtual hosts in the configuration by uncommenting "Include conf/extra/httpd-vhosts.conf" in httpd.conf. I have tested the configuration with "httpd -t" and gets "Syntax OK", but localhost works but soborghave gives me a 403 Forbidden when I clicks on the project from the localhost page.

I can't see the problem, can somebody help me figure out where it all goes wrong?

Options: ReplyQuote
Re: Problem configuring virtual host
Posted by: RiggsFolly (---.dynamic.dsl.as9105.com)
Date: October 17, 2014 11:17AM

What happens when you just enter

'http://soborghave'

into the browser address?

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Problem configuring virtual host
Posted by: zagadka (---.cpe.webspeed.dk)
Date: October 27, 2014 04:58PM

RiggsFolly Wrote:
-------------------------------------------------------
> What happens when you just enter
>
> 'http://soborghave'
>
> into the browser address?


At the time of writing an HTTP 403 Forbidden, now a 200 OK (see below for explanation).

Through trial and error I have since tracked down the problem to Apache not be fully compatible with previous version. I my project I have inherited a .htaccess file that contains a LIMIT section, and while that file worked perfectly on previous versions it caused the problem here. It had "order allow,deny" and then "allow from all" and deny from all". For some reason the deny cause took precedence and access was denied, despite it having worked flawlessly with previous versions which sent of my radar to being with. Removing the deny clause restored access.

Please don't ask why the previous developer would do a LIMIT like this as I fail to understand it myself.

Options: ReplyQuote
Re: Problem configuring virtual host
Posted by: RiggsFolly (---.dynamic.dsl.as9105.com)
Date: October 27, 2014 05:07PM

Oh I can tell you why.


There are a LOT OF MUPPETS out there who look at help provided by other MUPPETS without actually trying to understand the syntax. So this is what you get !


Reason for the presedence is


'Order Allow,Deny' says process the Allows, and then process the Denies. Hence 'deny from all' does exactly that.

If it had been 'Order Deny,Allow` then the last thing processed would have been the `Allow's` Although having both `Allow from all` and `Deny from all` makes NO SENCE IN ANY SITUATION to anybody but a MUPPET.


But thanks for clearing up the situation.

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-



Edited 1 time(s). Last edit at 10/27/2014 05:07PM by RiggsFolly.

Options: ReplyQuote
Re: Problem configuring virtual host
Posted by: tuxor (---.prod-infinitum.com.mx)
Date: December 09, 2014 09:39PM

Hi, I did all yo said here to create a virtual host, but when i go to my project url, example ejemplo.pv, at the end of the pat appears "\" like this ejemplo.pv\ and i can't see the index.php because the \ appears automatically. How can I fix it?

thank you.

Options: ReplyQuote
Re: Problem configuring virtual host
Posted by: RiggsFolly (---.as43234.net)
Date: December 09, 2014 10:09PM

Tuxor,

Posting the same message on 3 different threads does not make your problem more inportant. Its just annoying.


START A NEW THREAD !!!

And answer these questions [forum.wampserver.com]
before describing what your actual problem is.

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote


Sorry, only registered users may post in this forum.