I am using Apache 2.2.6 with suPHP 0.6.2 and PHP 5.2.6 and I am trying to use an Alias in order to route all requests on a certain URL trough a PHP script. I want all requests to /test to go through index.php. In the Apache virtualhost config I have set up an Alias Alias /test /index.php
. index.php is just a dummy script containing the following:
<?php
phpinfo();
?>
Requesting http://localhost/index.php works and gives the expected output, however requesting http://localhost/test does not and gives me a 403 error, the error.log contains the following:
[Wed Jan 27 17:13:19 2010] [error] [client 127.0.0.1] client denied by server configuration: /index.php
What is wrong with my Alias?
Edit: I almost forgot to mention that rewriting /test to /index.php through mod_rewrite works as well, however I want to avoid mod_rewrite on my production server if possible.