Sebastian, h:message2 is not a real component yet.   It's just
something that usrwagner was proposing.

There's no easy solution to what you're asking for yet.
JSF 1.2 has added a requiredMessage attribute that would do what you want.

https://javaserverfaces-spec-public.dev.java.net/issues/show_bug.cgi?id=81

h:message2 could in theory cycle through the list of messages and
replace certain messages with a custom one.   However, it'd be very
hard to determine which message was the one you wanted to replace.

On 11/4/05, Sebastian Dimunzio <[EMAIL PROTECTED]> wrote:
>
>
> Thanks! you
>
>
> 2005/11/4, [EMAIL PROTECTED] <[EMAIL PROTECTED]>:
> >
> > What I have forgotten
> > The specification should be like this
> >
> > <h:message2 style="color:red" for="firstname"
> >           value="You must fill the first name"/>
> >
> >
> > >-- Original-Nachricht --
> > >Reply-To: "MyFaces Discussion" <[email protected] >
> > >Date: Fri, 4 Nov 2005 15:46:26 +0100
> > >From: [EMAIL PROTECTED]
> > >Subject: RE: custom error message
> > >To: "MyFaces Discussion" < [email protected]>
> > >
> > >
> > >
> > >I would like to have such a tag component.
> > >
> > >>-- Original-Nachricht --
> > >>Reply-To: "MyFaces Discussion" < [email protected]>
> > >>Date: Fri, 4 Nov 2005 11:36:50 -0300
> > >>From: Sebastian Dimunzio <[EMAIL PROTECTED]>
> > >>To: [email protected]
> > >>Subject: custom error message
> > >>
> > >>
> > >>Hi!
> > >>Somebody know the way to show a custom error message for each field on
> > my
> > >>form, for example "You must fill the first name"
> > >>
> > >>Thanks!
> > >>
> > >>Saludos
> > >>Sebastian Dimunzio
> > >
> >
> >
>
>
>
> --
> Sebastian Dimunzio
>

Reply via email to