okay, let me more clear on this. here is the text that I want to save in DB, entered in t:textArea-
<h:inputTextarea value="#{discussion.contents}" ></h:inputTextarea>
Line1, this is test string on line one.
This is test string on line second.
I persist above text in mysql db using entityManager.persist(obj). I have a setter/getter for contents of String type in POJO(entity class) and CLOB in database. I am not doing any special processing for this. When, I browse the database table it shows as it is entered,preserving the next line, as shown below -
Line1, this is test string on line one.
This is test string on line second.
But, when I display this text in browser it is displaying as one string as shown below -
Line1, this is test string on line one. This is test string on line second.
Any idea, how to display the text in browser as entered by user preserving the next line.
Thanks for your help.