Hi!
I
thought the renderer of h:message does replace the line terminator sequence \n
with HTML, but that seems not to be the case. I tested to use
"<br/>" (without double quotes), and this also doesn't work.
The string is just diplayed as text. (I also tried <br> without
success.)
I think it's an important use case to display error messages in multiple lines. Does anybody have a solution, or is this just impossible at the moment?
I think it's an important use case to display error messages in multiple lines. Does anybody have a solution, or is this just impossible at the moment?
Regards,
Matthias
-----Ursprüngliche Nachricht-----Are you sure \n isn't working? (Remember that \n is meaningless in html (it is a space))
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]Im Auftrag von Andrew Robinson
Gesendet: Dienstag, 10. Januar 2006 16:34
An: MyFaces Discussion
Betreff: Re: How to define line breaks in a resource bundle message?
If you are using output text, and you want a new line in HTML you may have to use "<br/>". I haven't tested this, but I'd imagine this may work for you
On 1/10/06, Matthias Kahlau <[EMAIL PROTECTED]> wrote:Hi Dave,
many thanks. If my understanding is correct, the line terminator sequence \n
should work. But I tried it using h:message, and it doesn't work. Is it
possible that h:message is not capable of rendering the line terminator
sequence appropriately?
Regards,
Matthias
> -----Ursprüngliche Nachricht-----
> Von: users-return-15012-mkahlau=[EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]Im Auftrag
> von Dave Brondsema
> Gesendet: Dienstag, 10. Januar 2006 14:27
> An: MyFaces Discussion
> Betreff: Re: How to define line breaks in a resource bundle message?
>
>
> Matthias Kahlau wrote:
> > Hi!
> >
> >
> > Is it possible to define a line break in a resource bundle
> message used for
> > h:message? I already tried \n and <br>, but that didn't work...
> >
>
> Resource bundles use a java Properties class. See the "load" method at
> http://java.sun.com/j2se/1.5.0/docs/api/java/util/Properties.html
>
>
> --
> Dave Brondsema
> Software Developer
> Cornerstone University
>