http & https not separated

Problems with the Windows version of XAMPP, questions, comments, and anything related.

http & https not separated

Postby magren » 24. November 2007 00:08

Hi.
Bare with me, i'm new to apache ;)
I have two websites running on the same apache. www.domain.com and portal.domain.com
The first site (www.domain.com) will run on port 80 only and the other (portal.domain.com) will be an https web (443) only.

My problem is that i can surf to https://www.domain.com and then the https://portal.domain.com site loads.
Vice versa when i surf to http://portal.domain.com the www.domain.com site loads.

What have i missed?

httpd-vhosts.com
<VirtualHost *:80>
ServerAdmin webmaster@dummy-host2.example.com
DocumentRoot "D:/xampp/htdocs/www-site"
ServerName www.domain.com
## ErrorLog @rel_logfiledir@/dummy-host2.example.com-error_log
## CustomLog @rel_logfiledir@/dummy-host2.example.com-access_log common
</VirtualHost>

httpd-ssl.conf
<VirtualHost _default_:443>
# General setup for the virtual host
ServerAdmin webmaster@dummy-host2.example.com
DocumentRoot "D:/xampp/htdocs/portal-site"
ServerName portal.domain.com
magren
 
Posts: 1
Joined: 23. November 2007 23:42

Postby LooseCannon » 26. November 2007 15:07

Hello and Welcome magren.

I'm barely beyond being 'new' to Apache, so just some simple points from me and they might be inappropriate. Shared learning and all that... Here goes.

DocumentRoot doesn't use speech marks, so try:
DocumentRoot D:/xampp/htdocs/www-site
DocumentRoot D:/xampp/htdocs/portal-site


The VirtualHost bracket for the second vhost should read:
<VirtualHost _default_ *:443>
ie, add a space and asterix before the collon, if you want requests from all hosts to be answered.
User avatar
LooseCannon
 
Posts: 162
Joined: 18. September 2007 12:07
Location: Hampshire, UK


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 117 guests