Submitted by novoops on Wed, 07/01/2009 - 14:12
What would you recommend as the best method to setup a site where the unsecured domain can be reached at http://www.example.com, but the secured site is reached via https://secure.example.com?
Obviously, this will require a dedicated IP address in order to support SSL with Apache. If I were to setup www.example.com as a virtual server, I suspect I can then setup secure.example.com as an alias for it. However, will this then cause any problems when setting up the SSL certificate for the domain?
FWIW, a couple of lines of php code at the beginning of an index.php file can be used to "redirect" the user if they go to the wrong "domain".
Status:
Closed (fixed)
Comments
Submitted by andreychek on Wed, 07/01/2009 - 14:23 Comment #1
I have a very similar setup as you.
What I did is:
At that point, going to https://secure.example.com works perfectly, as does plain old http://example.com.
-