echo nl2br("foo isn't\n bar"); Output:
echo nl2br("foo isn't\n bar");
foo isn’t bar
What good is this you say. Well if you are like me and use striptags() in your forms you need a way to insert the linebreaks back on the echo. This will do it