Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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 have a shared hosting pack with 2 domains, one is the default domain bought with the pack, and the second will be pointed to a sub-directory within my root.

The problem is that I want both the domains to point to sub-directories.

The current architecture is:

1- -> www/

2- -> www/domain2/

and because this is not very tidy, as the second domain's directory will look like a sub-directory in the first domain, I want the architecture to be like this:

1- -> www/domain1/

2- -> www/domain2/

to keep a clean tree.

I think this would be achieved by a .htaccess file located in the root www/

So, how to do it? and is there any side effects?


share|improve this question
Which shared hosting? – Aren B Feb 18 '11 at 1:11
at OVH – MohamedKadri Feb 18 '11 at 1:28
Then you need to discuss this with OVH support. – John Gardeniers Feb 18 '11 at 2:14

Your going to need to access the Apache config and change the directory there for your Vhosts.

share|improve this answer
how to do that in a shared hosting (OVH) – MohamedKadri Feb 18 '11 at 0:33

What I have seen done in some cases is people get an admin domain name and then place the individual sites in separate directories. -> www/ -> www/domain1 -> www/domain2
share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.