Re: /n not working

From: Date: Sat, 26 Jul 2003 16:50:11 +0000
Subject: Re: /n not working
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-157016@lists.php.net to get a copy of this message
Thomas Hochstetter wrote:
Hi there. I got a question from someone why the following (from the manual) will not bring the desired output: <?php /* if I open the following txt file and in explorer*/ $text = "The quick brown fox jumped over the lazy dog."; $newtext = wordwrap($text, 20); echo "$newtext\n"; /*my output is the following The quick brown fox jumped over the lazy dog. */ /*this should however have the following output according to the php manual The quick brown fox jumped over the lazy dog. */ ?> Is this a php.ini setting?
HTML does not render newlines. You need to use <br />. View the source of this code in your browser and you'll see everything is on it's own line. -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ PHP|Architect: A magazine for PHP Professionals – www.phparch.com

« previous php.general (#157016) next »