wamp test website error
Posted by: colin104 (---.cpe.net.cable.rogers.com)
Date: June 21, 2016 06:41PM

I have created a database with 1 test website already. I have tried to make another website by bringing another wordpress folder into wamp/www, and changed the wpconfig.php to the wamp database I have created. However, when I try to go to the localhost/sitename, it gives me a blank page.

Anyone know how to solve my problem? I'm assuming it's a one step fix

Options: ReplyQuote
Re: wamp test website error
Posted by: Otomatic (Moderator)
Date: June 21, 2016 06:48PM

Hi,

You must use VirtualHost, one VirtualHost for each wordpress website : The need for Virtual Host

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

Options: ReplyQuote
Re: wamp test website error
Posted by: colin104 (---.cpe.net.cable.rogers.com)
Date: June 21, 2016 06:51PM

I don't believe I have a virtual host for my first website, and it runs perfectly. Is there a reason that the second site cannot be set up?

the wamp localhost says I can set up a virtual host, so should I just go through this process?

Options: ReplyQuote
Re: wamp test website error
Posted by: colin104 (---.cpe.net.cable.rogers.com)
Date: June 21, 2016 07:52PM

I have now made a virtual host named "test". However the project linked to it does not open.
"the requested URL /planning was not found on this server"

The "planning url is in wamp\www, and was linked to the virtual host upon inception.

Thoughts on how to fix this?

Options: ReplyQuote
Re: wamp test website error
Posted by: Otomatic (Moderator)
Date: June 22, 2016 09:31AM

Hi,

Suppose your first Wordpress local site is called wordpress1 and is in c:/wamp/www/wordpress1/ and the second is called wordpress2 and is in wamp/www/wordpress2/

The content of c:\wamp\bin\apache\apache2.4.xx\conf\extra\httpd-vhosts.conf must be
(xx is ne version number of Apache you use)
<VirtualHost *:80>
	ServerName localhost
	DocumentRoot c:/wamp/www
	<Directory  "c:wamp/www/">
		Options +Indexes +Includes +FollowSymLinks +MultiViews
		AllowOverride All
		Require local
	</Directory>
</VirtualHost>

<VirtualHost *:80>
	ServerName wordpress1
	DocumentRoot c:/wamp/www/wordpress1
	<Directory  "c:wamp/www/wordpress1/">
		Options +Indexes +Includes +FollowSymLinks +MultiViews
		AllowOverride All
		Require local
	</Directory>
</VirtualHost>

<VirtualHost *:80>
	ServerName wordpress2
	DocumentRoot c:/wamp/www/wordpress2
	<Directory  "c:wamp/www/wordpress2/">
		Options +Indexes +Includes +FollowSymLinks +MultiViews
		AllowOverride All
		Require local
	</Directory>
</VirtualHost>
and the content of C:\Windows\System32\drivers\etc\hosts file must be:
127.0.0.1 localhost
127.0.0.1 wordpress1
127.0.0.1 wordpress2
::1 localhost
::1 wordpress1
::1 wordpress2
to launch your local sites , in the adresss bar of the brownser you type : 'http://wordpress1/' or 'http://wordpress2/'

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

Options: ReplyQuote


Sorry, only registered users may post in this forum.