yaf icon indicating copy to clipboard operation
yaf copied to clipboard

Yaf_Route_Static(default route) 在多模块的路由判断不准确

Open zivee opened this issue 9 years ago • 3 comments

// 假设配置
$conf = array(
   "application" => array(
      "modules" => "Index,Blog",
   ),
);

路由结果如下: Module + controller + action: http://example/blog/archive/list module == blog controller == archive action == list

Module + controller: http://example/blog/archive module == null controller == blog action == archive

Module http://example/blog/ module == null controller == blog action == null

zivee avatar Nov 13 '15 07:11 zivee

可以自己写一个以 /Module/Controller/Action 方式优先的路由器, 而不是 Yaf 自带的 /c/a 优先

fnu avatar Dec 08 '15 09:12 fnu

我也遇到了这个问题, 这应该是一个bug。

zhoushenn avatar Jan 09 '16 08:01 zhoushenn

module == null 其实是 module == index模块 是优先匹配的 然后才匹配其他的 没毛病

letwang avatar Dec 06 '18 02:12 letwang