【发布时间】:2020-10-23 17:23:25
【问题描述】:
我有两种路线。
这行得通:
http://localhost/monitor/test1
这不是:
http://localhost/monitor/test2/test3
这是我目前的规则:
RewriteRule (^[^/]*$) public/$1 [L]
我知道这个只匹配最后一个斜线。如何更改正则表达式以匹配这两种情况?
【问题讨论】:
-
能否请您从
http://localhost/monitor/test2/test3告诉我们您要重定向到哪个网址? -
@RavinderSingh13 我想重定向到 public/test2/test3
标签: regex .htaccess url mod-rewrite slim