Hi All
The current project we are working on has been specified to include
the field name in the required validation failure i.e. failing to
complete the surname field should show the message "The Surname is
required".
I know I can set this on a per field basis but I was wondering if
there is a way to do this on a per form default basis. We've
successfully changed the default message using
sfValidatorBase::setRequiredMessage('This field is required');
sfValidatorBase::setInvalidMessage('The value provided for this field
is invalid');
But this does not include the field name in the message, I was hoping
something like this would work but it doesn't.
sfValidatorBase::setRequiredMessage('This %field% is required');
sfValidatorBase::setInvalidMessage('The value provided for %field% is
invalid');
Can anyone point us in the right direction?
Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"symfony users" 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-users?hl=en
-~----------~----~----~----~------~----~------~--~---