测试代码:public function info($id){
echo url('index/index/info',['id'=>10])."
";
return "{$id}";}
运行结果:/web/public/index/index/info/id/10.html
已经配置了路由:'url_route_on' => true,
'url_route_must' => false,
'posts/:id' => 'index/index/info'
但是访问的路径用localhost/posts/2.html就报错,这是什么问题?
posts/:id=>'/web/public/index/index/info'