开发者

Another apache rewrite question

In my scenario I redirect

"/index/../" to "/index.php?act=..".

I was开发者_JS百科 wondering how can I restrict direct access to "/index.php" but still be able to redirect from "/index/../"?

P.S. "/../" is anything... it seems you can't use * there. O.o


Add the following to your rewrite script RewriteCond %{REQUEST_URI} !index.php$ [NC]. This rule will fail for /index.php (but not /index.php?whatever). At least I think it will, I haven't tested it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜