xyn Posted July 10, 2006 Share Posted July 10, 2006 Hi guys,In MYSQL Is it possible toautomatically detect line breaks instea dof using "<br>" example:i want to write:Hey dude, [color=yellow]<br>[/color]Please can You help me.And instead of having to place <br> it automatically realises it. Link to comment https://forums.phpfreaks.com/topic/14228-line-breaks/ Share on other sites More sharing options...
ShogunWarrior Posted July 10, 2006 Share Posted July 10, 2006 Do you mean adding [b]<br />[/b] when outputting to a browser? Link to comment https://forums.phpfreaks.com/topic/14228-line-breaks/#findComment-55839 Share on other sites More sharing options...
xyn Posted July 10, 2006 Author Share Posted July 10, 2006 yeah, basically replacing a line break with <br> when outputting... Link to comment https://forums.phpfreaks.com/topic/14228-line-breaks/#findComment-55844 Share on other sites More sharing options...
GingerRobot Posted July 10, 2006 Share Posted July 10, 2006 use the function nl2br() on the text from your database. Link to comment https://forums.phpfreaks.com/topic/14228-line-breaks/#findComment-55847 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.