if a user requests a file in the directory /foo in want the Apache to serve the requested file from /bar.
It works like expected When i use
- Code: Select all
RewriteEngine On
RewriteRule ^/foo/(.*)$ /bar/$1
in the configuration file of the virtual host.
But when i place the rule in a .htaccess file nothing happens.
In order to get it to work i have to change it (remove the / of /foo) to
- Code: Select all
RewriteEngine On
RewriteRule ^foo/(.*)$ /bar/$1
Coult someone please explain that to me?
regards
Robert