开发者

Chain several routes in zend framework

How can I get these 2 routes (languages, amdin) to work.. alone admin, or language will work but together they will fail :(

; Admin route
resources.router.routes.admin.type = Zend_Controller_Router_Route
resources.router.routes.admin.route = ":admin"
resources.router.routes.admin.reqs.admin = "admin"

; Language route
resources.router.routes.language.type = Zend_Controller_Router_Route
resources.router.routes.language.route = ":language"
resources.router.routes.language.reqs.language = "^(nl|en)$"
resources.router.routes.language.defaults.language = "nl"

; Default route chain
resources.router.routes.default.type = Zend_Controller_Router_Route_Chain
reso开发者_如何学运维urces.router.routes.default.chain = "language, admin, defaultmodule"


Well, of course. These routes are overlapping, while they should have been different.

; Admin route
...
resources.router.routes.admin.route = "admin/:admin"
...
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜