Re: ho to remove an empty space

From: Date: Wed, 26 Mar 2003 05:12:55 +0000
Subject: Re: ho to remove an empty space
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-141055@lists.php.net to get a copy of this message
On Mon, 24 Mar 2003 22:10:28 -0800, Webdev <WebDev@browseabit.com> wrote:
somehow when I have try to develop an application where I read five or six values into an individual arrays the array who carries the emails has the
email and     an additional empty field after the email somehow complex well
they way the information has been stored is that the email was the last value in the line of arrays and somehow carries always an empty field or the tab field I can see when I upload the data in binary mode however I tried around for some time how do remove an empty space in an erray I tried arround with $E2= str_replace(" ", "", $Email); and I tried as well $E2= str_replace("&nbsp;", "", $Email); with no success it totally ignored the empty space in the email what is stored in this way:|data1|data2|email@somewhere.net |data3|etc...|||||||. when I phrased the data file any help and advice would be appreciated...
Are you certain it is a space and not something like a linebreak? If it's at the end of the line, you might consider ltrim or rtrim, which would eliminate most whitespace characters from the beginning or ending of the string. -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/

« previous php.general (#141055) next »