I am collecting text from a textarea. The text has line breaks in it. I then save it to a database.
However when I retrieve it from the database and display it back in a textarea for editing, the line breaks are gone and the text turns into one long run-on string.
I would like the line breaks originally there to reappear. How can I make the line breaks appear as they should when inserted back into a textarea?
Note: I cannot just convert them to a <br> because this is going inside a textarea where <br> elements would not get rendered, but just written out as text. I want the actual line breaks.
\njust fine on its own.