Virtual Host
Posted by: pakoch (---.ph.ph.cox.net)
Date: January 17, 2018 04:24AM

Hello, I have loaded WAMP onto a system with Win 10 installed. Everything appears to be running OK. The icon is green and all services are running. I have followed the steps to create a virtual host site by coping the path of my folder (on the same computer) into the WAMP virtual host setup screen. However, I am unable to connect. I get a message from Windows saying the "This site can't be reached" ; it refused to connect. I have checked permissions for that folder, reloaded WAMP and stopped and restarted all services, but I still am unable to connect to the local folder. Also, just connecting to local host works OK, it is just when I setup a site in another folder that I have problems. Can anyone give me some recommendations?
Thank You,
Peter Koch

Options: ReplyQuote
Re: Virtual Host
Posted by: Otomatic (Moderator)
Date: January 17, 2018 09:56AM


Options: ReplyQuote
Re: Virtual Host
Posted by: RiggsFolly (Moderator)
Date: January 17, 2018 10:54AM

Hi,

Did you add your Virtual Hosts site name to the HOST file?

c:\windows\system32\drivers\etc\hosts

ignore the commented lines you may find in there, a commented line starts with a #


127.0.0.1 localhost
::1 localhost

127.0.0.1 yoursite
::1 yoursite

---------------------------------------------------------------------------------------------
(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 01/17/2018 12:04PM by Otomatic.

Options: ReplyQuote
Re: Virtual Host
Posted by: pakoch (---.ph.ph.cox.net)
Date: January 18, 2018 04:05AM

Hi, Yes, I checked my hosts file and the site name is present. The two un-commented lines are:
127.0.0.1 MySiteName.dev
::1 MySiteName.dev

I am running WAMP 3.1.0, PHP 7.1.9. But I appears to me that the problem must be coming from my Win 10 system, because everything in WAMP is running, green and OK.

If I place a site within the folder that WAMP is located, I can see that. It is only the virtual host function that seems not to work.

Thank You,
PAKoch

Options: ReplyQuote
Re: Virtual Host
Posted by: Otomatic (Moderator)
Date: January 18, 2018 09:25AM

Hi,

With which browser?
Have you tried with other browsers?

Quote

The two un-commented lines are:
127.0.0.1 MySiteName.dev
::1 MySiteName.dev
It's missing:
127.0.0.1 localhost
::1 localhost

Avoid case-sensitive toying. One day you will do it on a file name or PHP variable and you won't understand why it doesn't work.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote


Sorry, only registered users may post in this forum.