I've posted the following on several forums, however, they all say it can't be done. I know for a fact this is NOT true and it can be done, because it has been done. Plus I hope I"m posting this in the correct area, because it is on a Linux Server.
I understand the fact that I can not have multiple SSL virtualhosts on the same IP and or port. I know the following can be done because hosting companies like 1&1 do this.
I have an SSL cert built for domain1.com so it can be accessed by http or https without any problems. However, because of this domain2.com can only be accessed by http. If I attempt https it will show domain1.com. What I want to have happen is if someone types
https://www.domain2.com, it forwards to
https://www.domain1.com/domain2.com.
I have setup a symlink so you can type
https://www.domain1.com/domain2.com and it works, but how can I make this happen automatically with apache and not having to rewrite all my website's code?
I'm running Slackware 12 (kernel 2.6.22.2)
Apache 2.2.8 with mod_ssl
php 5.2.5 (if that really matters)
I don't see why anymore info would be needed here, but if it is I will reply.
Hope this all makes sense. Thank you all in advance.