i have a tag like this:
<h:inputTextArea cols="60" rows="10" styleClass="text_area">
when the user enter a text like this:
The output appear: abc
it must be as input.
can anybody help me ???
posted 7 years ago
You need to output it preformatted. You can either output it in a h:inputTextarea or in a component/HTMLelement to your choice where on you apply the CSS white-space:pre property.
If you don't want to output it preformatted, but as truetype or whatever text, then you need to convert newlines to HTML <br> elements. You know, a linebreak in plain HTML is to be represented with the <br> element. You can use String#replace() or JSTL's fn:replace for this.
Edit: sorry for countless edits; the darn forum engine apparently got a new bug in parsing HTML entities.