I want to customize the error handling in symfony2 forms.
If a error occured, the input field should have another class to show that the input value isn’t correct.
How can I do this?
I know that I have to customize the rendering template, but I don’t really know how to do this. Do I have to customize all input templates? And how can I check, if the input contains errors?
You could use form themes and override default theme. Ex. See how MopaBootstrapBundle theme apply exactly you want using the Twitter Bootstrap philosophy.