2010年7月10日星期六

Re: [fw-mvc] Problem with custom route

Take a look at the exception trace. That seems more like a url constructing exception than a routing exception.

--
Hector


On Sat, Jul 10, 2010 at 10:12 AM, Marcus Stöhr <dafish@soundtrack-board.de> wrote:
Hi.

I define a named route through my application.ini:

resources.router.routes.userprofile.route = "/user/profile/:id/:name/*"
resources.router.routes.userprofile.defaults.controller = "profile"
resources.router.routes.userprofile.defaults.action = "index"
resources.router.routes.userprofile.defaults.module = "user"

When I try to access the following url: /user/profile/1/foobar/

I get an exception: Zend_Controller_Router_Exception: id is not specified

I have no idea where the problem is. Any advice?

- Marcus


没有评论: