in reply to Regexp multiple match
Hi jeteve,
What you want is the /g modifier, as this, highly contrived, example will show
#!/usr/bin/perl use strict; use warnings FATAL => "all"; my $s = "batcatbetnetbitfit"; my $p = "b.t"; my @matches = $s =~ /$p/g; print "@matches\n"; __END__ returns bat bet bit
cheers
thinker
|
|---|