PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
I am pulling 'body' text from a table to use in a template and I don't want to have to type the <br> in the actual table text. I would like to handle replacing the CRLF as its pulled from the table and before its put into template. I am trying
$body=eregi_replace("\r\n","<br>",$body);
but the \r\n is where I am screwing up. Can anyone show the correct way to do this?