I don't think it's a problem with the specific code you're using to remove newlines. Rather, the problem is that for some reason you have actual back-slashes followed by "n" characters in the text, not newline characters. (It's as if the text were defined as $text = 'first line\\nsecond line'; rather than $text = "first line\nsecond line";)
"Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
~ Terry Pratchett in Nation
Well I must admit that it seems to occure when a copy/pate is done.
The /n can not be seen in the form and only shows up after accepted into the db and then re-displyed.
I used to use nl2br() before input to db but read a few threads that said it wasn't necassary - just change the display.
Now, the point is how do I change these this to <br> ?
Bookmarks