in reply to Regular Expression To Extract Multiple Matches Pattern
If you're replacing the string you're searching for, there's no need to use m/// at all ...
while ( $teststring =~ s/\b([a-z]+-[a-z]+-[a-z]+)\b/phrase/i ) { print $1; }
--k.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Regular Expression To Extract Multiple Matches Pattern
by talexb (Chancellor) on Jan 07, 2002 at 19:37 UTC | |
by Kanji (Parson) on Jan 07, 2002 at 20:15 UTC | |
by Cody Pendant (Prior) on Jan 08, 2002 at 01:02 UTC | |
|
Re^2: Regular Expression To Extract Multiple Matches Pattern
by Aristotle (Chancellor) on Jan 07, 2002 at 17:49 UTC |