Hi,I have following two queries:[1] Can i host two websites with different domain names on same webserver?[2] We have installed SSL Certificate on Apache Webserver. But when we browse the website with its domain name (without prefixing www), following error message is received:---There is a problem with this website's security certificate. The security certificate presented by this website was issued for a different website's address. Security certificate problems may indicate an attempt to fool you or intercept any data you send to the server. We recommend that you close this webpage and do not continue to this website. Click here to close this webpage. Continue to this website (not recommended). More information ---Thanks,
Hello there, Yes, you can host more than one website on the same web server, but your setup may dictate otherwise. Regarding your SSL issue, if the certificate was purchased with the 'www', then the certificate is only valid using the 'www', thus the reason that the non 'www' is flagging an error. Regards, Chris
1. You can host multiple websites using virtual host directives. More information on how to create virtual host configurations on Apache web server you can find at http://httpd.apache.org/docs/2.2/vhosts/ 2. You can create a .htaccess file to redirect all 'non-www' to 'www' for both the HTTP and HTTPS requests. Create a .htaccess file to your website’s root directory and add the code below: Options +FollowSymlinks RewriteEngine On RewriteCond %{HTTP_HOST}//s%{HTTPS} ^www\.(.*)//((s)on¦s.*)$ [NC] RewriteRule ^ http%3://%1%{REQUEST_URI} [L,R=301]
Yes, you can host multiple websites on the same servers. This is when VirtualHost entries comes in picture wherein you can host point multiple websites to a single IP address. SSL is host based so it will work only on the host which was used when issuing the SSL certificate.