note 101642 added to function.nl2br

From: Date: Fri, 31 Dec 2010 15:29:31 +0000
Subject: note 101642 added to function.nl2br
Groups: php.notes 
Request: Send a blank email to php-notes+get-175370@lists.php.net to get a copy of this message
The most important note is missing that nl2br does not remove \n character. It replaces \n with <br />\n <?php $x = "A\nB"; $y = nl2br( nl2br( $x ) ); // produces "A<br /><br />\nB" ?> In addition \r is not removed/replaced either. ---- Server IP: 69.147.83.197 Probable Submitter: 89.167.220.4 ---- Manual Page -- http://www.php.net/manual/en/function.nl2br.php Edit -- https://master.php.net/note/edit/101642 Del: integrated -- https://master.php.net/note/delete/101642/integrated Del: useless -- https://master.php.net/note/delete/101642/useless Del: bad code -- https://master.php.net/note/delete/101642/bad+code Del: spam -- https://master.php.net/note/delete/101642/spam Del: non-english -- https://master.php.net/note/delete/101642/non-english Del: in docs -- https://master.php.net/note/delete/101642/in+docs Del: other reasons-- https://master.php.net/note/delete/101642 Reject -- https://master.php.net/note/reject/101642 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#175370) next »