> On Sunday 11 March 2001 14:37, Jens wrote:
> > You have probably had this question a few times, but can anyone tell me
how
> > to detect "new line's" or breaks in form fealds from both PC and Mac.
And
> > then replacing the "new line" with a <br> so that I can use it for the
web?
>
> $string = nl2br( $string );
nl2br() don't replace the newlines with a <br> they insert a <br> before
the newline,
therefor you need something like:
$string = str_replace("\n", "<br>", $string);
--
Henrik Hansen
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]