thinkphp里面路由是不是必须加上模块名

浏览:1569 发布日期:2014/05/11 分类:求助交流 关键字: 路由
3.2版本中,比如下面的地址
完整的URL:
http://www.XXXX.com/Home/Index/nlist/id/1.html
能否写成
http://www.XXXX.com/nlist/1.html

配置文件
'nlist/:id'=>'Index/nlist',
它总是说找不到nlist模块,不知道咋回事。

----------------------------------------------------------

写成这样倒是可以访问
http://www.XXXX.com/Home/nlist/1.html
规则:'nlist/:id'=>'Index/nlist',

但是不是我想要的效果,无法隐藏模块名 这好郁闷。

最佳答案
评论( 相关
后面还有条评论,点击查看>>