The space is there so it does not break some old browsers which could thing it is "BR/" tag (yes, it does not exists). Change your logic or do preg_replace(array("\r\n","\n","\r"), '<br>', $string) instead - not tested

Chris Mach wrote:

Why does it put a space in there? <br />

It's screwing up my other script which displays just the first 50 words of
the news article by exploding each word into an array. So /> is showing up
after each break.

http://www.ticatfans.com/index.php


"Marek Kilimajer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]

nl2br()

Chris Mach wrote:

I have a simple little script that displays news articles that are

stored in


mySQL database.

However, when the script displays the data, it doesn't recognize the
returns/enters. So I have to put <br><br> when ever I want a new

paragraph


to begin.

How can I get my script to recognize the returns? is there any functions

for


this type of thing?

Thanks




-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to