This should do it for you:

$sring =~ s/^ +| +$//;

Brian Johnson
Partner/Systems Administrator/Programmer
Source1Hosting.tv, LLC (www.source1hosting.tv)
Source1Results.com, LLC (www.source1results.com)
I may be insane, but remember - The only
difference between an insane man and a
genius is his jacket.

> -----Original Message-----
> From: Rahul Garg [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, July 19, 2001 2:49 AM
> To: [EMAIL PROTECTED]
> Subject: Removing spaces
> 
> 
> Hello everybody,
> 
> A simple Q........
> well i want to remove spaces if any in the beginning and end 
> of a string.
> how to do this...........
> 
> 
> Waiting for Reply...........
> Thanx in advance........................
> 
> 
> 
> 
> .
> 
> 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to