in reply to A little regex help please!
More of the same, but
local $/; my $text = <DATA>; my ($number, $from) = $text =~ /mailbox (\d+).*?From:\s*([^\n]+)/;
It might be more efficient to replace the .*? with .*. Both will work.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: A little regex help please!
by japhy (Canon) on Jan 31, 2006 at 22:03 UTC |