开发者

php: newbie modrewrite question

i'm having a little issue with modrewrite under php. this is inside my .htaccess file:

RewriteEng开发者_开发技巧ine On
RewriteRule ^test.html$ test.php
RewriteRule ^index.html$ index.php

it works nicely with test.html -> test.php but i'm getting an 404 error when trying to acceses my domain like www.domain.com/index.html althought it's the same structure and should work .. :/ when using www.domain.com only it works.

any idea what's wrong with using index.php -> index.html?

thanks


It sounds like index.php doesn't exist.

When you go to http://www.domain.com it is going to hit index.html (or index.php) and in the case of index.html it WONT fire your rewrite rule (as the request uri is / or empty string)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜