advancedfuture Posted January 8, 2008 Share Posted January 8, 2008 So I am trying to output the data from a certain field in my database which has user uploaded content. Now I can do a query in mysql and see the paragraph/line breaks. But when I output the data it just puts it in one giant block of text... how do I go about rendering the paragraph breaks? Link to comment https://forums.phpfreaks.com/topic/84960-solved-rendering-linebreaks-from-database-output/ Share on other sites More sharing options...
papaface Posted January 8, 2008 Share Posted January 8, 2008 try echo nl2br($string); Link to comment https://forums.phpfreaks.com/topic/84960-solved-rendering-linebreaks-from-database-output/#findComment-433220 Share on other sites More sharing options...
advancedfuture Posted January 8, 2008 Author Share Posted January 8, 2008 that function was exactly what I was looking for! Thanks! Link to comment https://forums.phpfreaks.com/topic/84960-solved-rendering-linebreaks-from-database-output/#findComment-433221 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.