So I've got 2 domains pointing to the same hosting box. Let's say they are domain1.com and domain2.com for illustrative purposes. Right now both domains go to the root of the hosting folder, meaning they take you to the same place (basically domain2 is an alias for domain1). What I want is for domain2.com to actually take you to a separate part of the website, namely a specific folder/sub-domain, e.g. - subdomain.domain2.com
Now I know there is a hack-ish way to do this by using server side code and doing a redirect, but I'm trying to handle it at the DNS level. I tried creating a CNAME entry for domain2 that maps 'www' to 'subdomain.domain2.com' but then nothing works and loading domain2.com gives me the message 'This website is temporarily unavailable, please try again later.'
Anybody know the right way to address this? Thanks!
Now I know there is a hack-ish way to do this by using server side code and doing a redirect, but I'm trying to handle it at the DNS level. I tried creating a CNAME entry for domain2 that maps 'www' to 'subdomain.domain2.com' but then nothing works and loading domain2.com gives me the message 'This website is temporarily unavailable, please try again later.'
Anybody know the right way to address this? Thanks!