Re: getting rid of space at beggining of variable

2004-02-10 Thread Shiping Wang
At 01:28 AM 2/12/2004 +1100, David Inglis wrote: "bloggs, joe" which I then spilt into 2 using @names=split(/\,/, $contact) How about: #!perl -w use strict; my $contact = "bloggs, joe"; @names=split(/, /, $contact); print @names; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional comman

Re: getting rid of space at beggining of variable

2004-02-09 Thread Jeff 'japhy' Pinyan
On Feb 12, David Inglis said: >Can anybody tell me what I'm doing wrong I have a variable with a value >"bloggs, joe" which I then spilt into 2 using @names=split(/\,/, $contact) >I then have $names[1] with a space at the front, I have tried to remove >it by doing $name[1]=~tr/\s//; but it does

Re: getting rid of space at beggining of variable

2004-02-09 Thread John W. Krahn
"Randy W. Sims" wrote: > > On 02/11/04 09:28, David Inglis wrote: > > Can anybody tell me what I'm doing wrong I have a variable with a value > > "bloggs, joe" which I then spilt into 2 using @names=split(/\,/, $contact) > > I then have $names[1] with a space at the front, I have tried to remove

Re: getting rid of space at beggining of variable

2004-02-09 Thread Randy W. Sims
On 02/11/04 09:28, David Inglis wrote: Can anybody tell me what I'm doing wrong I have a variable with a value "bloggs, joe" which I then spilt into 2 using @names=split(/\,/, $contact) I then have $names[1] with a space at the front, I have tried to remove it by doing $name[1]=~tr/\s//; but it d

getting rid of space at beggining of variable

2004-02-09 Thread David Inglis
Can anybody tell me what I'm doing wrong I have a variable with a value "bloggs, joe" which I then spilt into 2 using @names=split(/\,/, $contact) I then have $names[1] with a space at the front, I have tried to remove it by doing $name[1]=~tr/\s//; but it does not remove the leading space. Any