Andy11548 Posted December 6, 2010 Share Posted December 6, 2010 How do I make it so that when I press the 'Return/Enter' key it is recognised as a new line?. Link to comment https://forums.phpfreaks.com/topic/220818-make-return-be-recognised-as-a-new-line/ Share on other sites More sharing options...
Pikachu2000 Posted December 6, 2010 Share Posted December 6, 2010 Clarify, please? Link to comment https://forums.phpfreaks.com/topic/220818-make-return-be-recognised-as-a-new-line/#findComment-1143620 Share on other sites More sharing options...
haku Posted December 6, 2010 Share Posted December 6, 2010 If you are talking about a text area, you need to pass it through a server-side function that will convert line breaks to <br> tags. If you are using php, you can use nl2br(). Link to comment https://forums.phpfreaks.com/topic/220818-make-return-be-recognised-as-a-new-line/#findComment-1143632 Share on other sites More sharing options...
Andy11548 Posted December 6, 2010 Author Share Posted December 6, 2010 If you are talking about a text area, you need to pass it through a server-side function that will convert line breaks to <br> tags. If you are using php, you can use nl2br(). Thanks very much, this works great . Link to comment https://forums.phpfreaks.com/topic/220818-make-return-be-recognised-as-a-new-line/#findComment-1143676 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.