开发者

apache htaccess - trailing slash and single entry point

I开发者_Python百科 need to have one entry point for my application - index.php. Before, i used to have such line of code:

RewriteRule ^(.*)$ /index.php [L]

Now, i need to force trailing slashes. I found out, that I can use such line:

RewriteRule ^(.*)$ http://%{HTTP_HOST}/$1/ [L,R=301]

But I want to know, how can I make it work both together.


try something like

RewriteRule ^(.*)$ /index.php/$1 [L]

or

RewriteRule ^(.*)$ http://%{HTTP_HOST}/index.php/$1/ [L]
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜