in reply to
Strip leading and trailing blanks
(maybe) Not quite as efficient as the two-step method already mentioned, but this works:
$name =~ s/^\s+|\s+$//g;
[download]
Update: typo caught by
Hofmator
, fixed.
Comment on
Re: Strip leading and trailing blanks
Download
Code
In Section
Seekers of Perl Wisdom