I have some routes like this one (using annotation style) :
/**
* @Route("/account.{_format}/{
id}", name="member_account_get", defaults={"id"="0","_format"="json"});
* @Method("GET")
*/
The controller class has a route prefix:
/**
* @Route("/member")
*/
When I use php app/console router:debug:
member_account_get GET /member/account.{_format}/{id}
What I'm finding is that the default _format is not working, and I get a
404 not found if I omit the .json.
For example:
app_dev.php/member/account/1007 does not work.
It seems that in order for the default to work, the _format needs to come
at the end of the route, and in fact, for this particular method, I provide
"list" capability through the id default, and
app_dev.php/member/account does work!
Known issue? Workaround? Misunderstandings on my part?
--
If you want to report a vulnerability issue on symfony, please send it to
security at symfony-project.com
You received this message because you are subscribed to the Google
Groups "symfony developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/symfony-devs?hl=en