Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using shared hosting on which I host a website and have got some "parked domains" (they show the same content as the master domain). I'd now like to catch those domains and show different content, effectively having separate websites for them.

I can change the DNS records and the .htaccess file, but I either end up creating endless loops or getting a 500 server error.

If a user visits they are shown content from the www directory. I'd like this to stay this way.

I'd like it so that if users visit they're shown content from the domain2 directory. The highest level at which I can create folders is /home/myaccount/www/ - this means that in the example above the content for domain2 would be stored in /home/myaccount/www/domain2

Can I achieve what I want using only DNS settings and url rewriting, or do I need to upgrade my hosting?

Any help would be greatly appreciated!


share|improve this question
you need to write yourself a little bit of code that loads a page depending on the domain used to connect :-) – Ash Palmer Oct 29 '10 at 12:35

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.