[EMAIL PROTECTED] wrote: > Is there a func or a onliner for removing blanks from both ends? > > I'm using these: > > $username =~ s/^\s+//; > $username =~ s/\s+$//; > > There got to be one out there!
Doing it in two steps is the way to go. Don't try to make one regex out of it. I usually write it this way, so I can process several variables at once: s/^\s+//, s/\s+$// for $foo, $bar, $baz; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]