[symfony-users] Re: Custom error messages

2009-11-03 Thread Mark Smith
OK, maybe I'm being thick, but that's not working for me: In the configure method I have: $this-setWidget(notes, new sfWidgetFormTextarea()); $this-setValidator(notes, new sfValidatorString(array ('min_length' = 0, 'max_length' = 4,'required' = false),array ('invalid'='Notes

[symfony-users] Re: Custom error messages

2009-11-03 Thread Gábor Fási
Yeah - instead of invalid, us max_length, see http://www.symfony-project.org/forms/1_2/en/B-Validators#chapter_b_sub_sfvalidatorstring On Tue, Nov 3, 2009 at 10:47, Mark Smith marksmith5...@jungle-monkey.com wrote: OK, maybe I'm being thick, but that's not working for me: In the configure

[symfony-users] Re: Custom error messages

2009-11-02 Thread David Ashwood
You can customize them: http://www.symfony-project.org/forms/1_2/en/02-Form-Validation#chapter_02_sub_customizing_error_messages On Mon, 2009-11-02 at 08:58 -0800, Mark Smith wrote: Is it possible to customise the error message coming from an sfForm so that the contents of the validated field