RE: [PHP] textarea -- what happens to my new lines

From: Date: Thu, 03 May 2001 12:45:34 +0000
Subject: RE: [PHP] textarea -- what happens to my new lines
Groups: php.general 
Request: Send a blank email to php-general+get-51263@lists.php.net to get a copy of this message
Try this: <?php $textfield = nl2br($textfield); echo $textfield; ?> For more info, have a look at http://www.php.net/nl2br. HTH Jon -----Original Message----- From: Stampe, Lars [mailto:lstampe@epson.co.uk] Sent: 03 May 2001 13:35 To: php-general@lists.php.net Subject: RE: [PHP] textarea -- what happens to my new lines Thanks for the idea, it didn't work, let me just explain a bit further! this is a simple version of the code input.htm:: <form name="form" method="get" action="show.php"> <textarea name="textfield" cols="45" rows="5" wrap="HARD"></textarea> <p> <input type="submit" name="Submit" value="Submit"> </form> show.php:: <?php echo $textfield; ?> When I put in : 1 2 3 4 I get: 1 2 3 4 how do I fix this ( want it to appear like it was typed!)? Regards Lars Stampe ********************************************************************** 'The information included in this Email is of a confidential nature and is intended only for the addressee. If you are not the intended addressee, any disclosure, copying or distribution by you is prohibited and may be unlawful. Disclosure to any party other than the addressee, whether inadvertent or otherwise is not intended to waive privilege or confidentiality' **********************************************************************

« previous php.general (#51263) next »