apache, php, ssl

in my web folder there is 2 folder. let say the first folder is abcd and the second is defg

so the abcd is for www.abcd.com and defg is for www.defg.com

i would like to do https://www.abcd.com. if i surf to http://www.abcd.com the domain is pointing perfectly to the abcd folder website. but when i add the S ( https )..the web server didnt show what is suppose to show. it only show apache Test Page and not the website from abcd...i already install some of the component such as below:

 Apache/2.0.53 (Unix) mod_ssl/2.0.53 OpenSSL/0.9.7d PHP/5.0.4 DAV/2 mod_perl/1.999.21 Perl/v5.8.6
Who is Participating?
ramazanyichConnect With a Mentor Commented:
did you create separate VirtualServer part for your ssl server ?
it seems not, because if apache doesn't find virtual server part for your https server then it uses default https server.
suppose you have following config for your http server:

<VirtualHost *:80>
ServerName www.abcd.com
DocumentRoot /path/to/abcd

for https server you should add following lines:
<VirtualHost www.abcd.com:443>
DocumentRoot /path/to/abcd
ServerName www.abcd.com:443
SSLEngine on
SSLCertificateFile conf/ssl.crt/server.crt
SSLCertificateKeyFile conf/ssl.key/server.key

NOTE: if you are usig namebased virtual hosts. It is not possible to use namebased virtual hosts for multiple SSL sites due to SSL nature, you should have different IP addresses per SSL site.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.