Thanks a lot Mike, it worked perfect!!!
Regards,
JV
-----Mensaje original-----
De: Mike Kienenberger [mailto:[EMAIL PROTECTED]
Enviado el: miércoles, 13 de septiembre de 2006 20:26
Para: MyFaces Discussion
Asunto: Re: Using personalized validation messages...
I added a message attribute to all of the tomahawk validators.
<t:validateRegExpr pattern='\d{5}' message='No, really, dude, you
gotta put in a standard US zip code, ya know?' />
should work.
On 9/13/06, Jorge Vásquez <[EMAIL PROTECTED]> wrote:
>
>
>
>
> Regards to all,
>
> Is there a way to make validators return personalized message Strings that
> are not necessarily found in message Bundles?
>
>
>
> For example, in the following code I would like to be able to specify the
> validator to use any message that I wished:
>
> <h:inputText id="regExprValue"
value="#{validateForm.regExpr}"
> required="true">
> <t:validateRegExpr pattern='\d{5}' />
> </h:inputText>
> <t:message id="regExprValueError" for="regExprValue"
> styleClass="error" />
>
> But unfortunately, in this case the tag validateRegExpr only has the
pattern
> attribute.
>
> Note: In the past I have used the method of creating a message String in
a
> messageBundle with the same Id as the one used by the component but in
this
> case we are not using messageBundles as internationalization strategy for
> our project.
>
> Any ideas?
>
> Thanks,
> Jorge Vásquez
>
>
>