So I created my first aff site and I am planning on creating a second for a totally different product. I don't want to purchase another hosting plan, can I just buy another domain name and alias it to the web host that I have for my first plan? My hosting company offers aliasing/masking/forwarding and I thought aliasing made the most sense. Any info or opinions on this would be much appreciated.
Thanks
I had one web site... say www.myfirstsite.com . I added a directory say... www.myfirstsite.com/secondsite/. I put all my second site content in that folder. I masked aliased domain name www.mysecondsite.com to that folder. It works great but the problem is that every page under that folder no matter what the url is, it is showing up as www.mysecondsite.com and thats it. I thought it would show up as www.mysecondsite.com/mypage.htm or something. Do I just have to go spend another $40 for a second hosting plan to run my second site? thanks
IP - this is like your phone number
domain name - this is like your name
DNS - this is like the phone book - look up the domain, get the IP
httpd.conf - this is like your local switchboard in your front office (assuming Apache here; I don't know IIS at all).
The hosting company doesn't really control the first three except insofar as they purchase some IP blocks. They only take care of what happens when, after a successful DNS lookup, traffic gets routed to their server by IP.
So you can go one of two ways
- shared IP
- separate IP for each account. In this case the httpd.conf is going to look like this
NameVirtualHost *<VirtualHost 127.0.0.2>
ServerAdmin me@example.com
DocumentRoot /home/htdocs/site1
ServerName site1.com
</VirtualHost><VirtualHost 127.0.0.3>
ServerAdmin me2@example.com
DocumentRoot /home/htdocs/site2
ServerName site2.com
</VirtualHost>
If you are sharing an IP, it will be similar, but it will achieve the separation by doing redirects or rewrites based on domain name and shunt the requests to a subdir. From the perpective of the visitor it should be the same unless they are savvy and go looking up your IP. For SEs, if they decide to ban you as a spammer/black hat SEO, all they need to do is a reverse DNS and ban everything mapped to that IP.
Realistically, most people with genuine sites don't need to worry about that, but at the same time most hosts will offer you an IP for about $1/month so if you're worried about sharing an IP, that's a cheap way to go.