.htaccess RewriteRule不能使用root'/'

我努力得到这个.htaccess重写正常工作:

<IfModule mod_rewrite.c> RewriteEngine On RewriteBase /subdir/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule (.*) old/$1 [L] </IfModule> 

我有这样的目录结构:

 /subdir/ .htaccess /old/ /wp/ 

我希望http://myserver.com/subdir/的所有请求都被重写为http://myserver.com/subdir/old/ ,期望那些指向/ wp /目录的请求。 上面的.htaccess工作正常,当一个文件或目录被指定(例如http://myserver.com/subdir/index.html ),但只有/ subdir /存在时,它给出了一个403响应(我假设403是因为我有目录列表禁用)。

非常感谢任何能指引我正确的方向的人。

这似乎是伎俩,即使我不知道为什么!

 <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /subdir/ RewriteCond $1 !^old/(.*) RewriteCond $1 !^wp/(.*) RewriteRule ^(.*)$ old/$1 [L] </IfModule>