html <textarea> problem
<textarea wrap="virtual" name="activity_description" rows="7" cols="70"></textarea>
for example I entered this message in my text area:
then i saved it to my database.. when i query and display it back the result would look like this:
"The quick. Brown fox. jump"
it doesn't retain the way the user entered the message, how do i fix this?
my PostgreSQL db column is set to recieve "character varying" and i do "INSERT INTO activity_info (activity_description)
i'm using java program so this problem is related to java :) and i think it's how my java program handles the message that needs to be fixed.
The text in your textarea are plain text and no html, so you must convert linebreaks.
As example :
"\n" -> "<br/>"