Re: Re: saving TEXTAREA data into mysql database

From: Date: Sat, 21 Jun 2003 20:25:46 +0000
Subject: Re: Re: saving TEXTAREA data into mysql database
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-152405@lists.php.net to get a copy of this message
Artoo wrote:
Is it better to use that function before the INSERT query and save it to the database like that or use that nl2br() function while displaying the results of the SELECT query,
Use it while displaying. You generally want to save the data in the database exactly as it was entered. This will allow you to display it back to the user for editing without them wondering what all the <br /> are in their sentences and also use it in other places, like mail or files... -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ PHP|Architect: A magazine for PHP Professionals – www.phparch.com

« previous php.general (#152405) next »