Displaying form validation errors in a template (Symfony)
Posted
by Jay
on Stack Overflow
See other posts from Stack Overflow
or by Jay
Published on 2010-04-07T13:29:54Z
Indexed on
2010/04/07
13:33 UTC
Read the original article
Hit count: 203
Hi,
let's say I have a blog with a module "post".
now I display a post like this: post/index?id=1
in the index-action i generate a new CommentForm and pass it as $this->form to the template and it is being displayed at the bottom of a post (it's just a textfield, nothing special). form action is set to "post/addcomment". How can I display the validation errors in this form? using setTemplate('index') doesn't work because I would have to pass the id=1 to it...
thanks
© Stack Overflow or respective owner