AW: [PHP-DB] Re: [PHP] Can't get rid of newlines

From: Date: Wed, 06 Dec 2000 14:48:54 +0000
Subject: AW: [PHP-DB] Re: [PHP] Can't get rid of newlines
Groups: php.db php.general 
Request: Send a blank email to php-general+get-28911@lists.php.net to get a copy of this message
Hi Luis, ... try "\r" instead, or better "\n" AND "\r". Greetinx, Mike (Germany) -----Ursprüngliche Nachricht----- Von: Louis Aslett [mailto:laslett@sixnet.net] Gesendet: Mittwoch, 6. Dezember 2000 15:43 An: Martin A. Marques Cc: php-general@lists.php.net; php-db@lists.php.net Betreff: [PHP-DB] Re: [PHP] Can't get rid of newlines My appologies, that e-mail should have gone: I'm trying to a some data from a <textarea> form element to an mSQL database. However, mSQL coughs shortly after the first newline. So, I did nl2br() to put all the newlines to <br>'s and then tried the following: $description=str_replace("\n"," ",$description); to get rid of the newlines. BUT! this string replace did absolutely nothing and the newlines are still in there! WHY? Thanks Louis ----- Original Message ----- From: Martin A. Marques <martin@math.unl.edu.ar> To: Louis Aslett <laslett@sixnet.net> Cc: <php-general@lists.php.net>; <php-db@lists.php.net> Sent: Wednesday, December 06, 2000 2:19 PM Subject: Re: [PHP] Can't get rid of newlines > On Wed, 6 Dec 2000, Louis Aslett wrote: > > > I'm trying to a some data from a <textarea> form element to an mSQL > > database. However, mSQL coughs shortly after the first newline. > > > > So, I did nl2br() to put all the newlines to <br>'s and then tried the > > following: > > What have toy tried? > > How are the new lines inserted in the textarea? Typing, copy and paste > from word? > > Saludos... ;-) > > > "And I'm happy, because you make me feel good, about me." - Melvin Udall > ----------------------------------------------------------------- > Martín Marqués email: martin@math.unl.edu.ar > Santa Fe - Argentina http://math.unl.edu.ar/~martin/ > Administrador de sistemas en math.unl.edu.ar > ----------------------------------------------------------------- > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net For additional commands, e-mail: php-db-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#28911) next »