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 would like to point all requests for a certain directory and all its possible subdirs to one documentroot.

So, for example, I get a lot of requests on many different subdirs here:

Point to the index.php file that resides in

What to add in apache2.conf ?

share|improve this question
up vote 0 down vote accepted

I would use mod_rewrite for achieving your goal, that will be much easier. see for an example. You "misuse" the 404 condition that arises when entering a "wrong" URL an redirect the user to the wanted file/page.

share|improve this answer
thank you Stefan – Apr 25 '11 at 12:49

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.