in reply to Re: Finding part of a file
in thread Finding part of a file
The problem with this code might be multivalued lines (because of \b)... Best regards, Strat{ local $/ = undef; my ($foundString) = ( <DATA> =~ /\bbanana\n(.*)\ngrape\n/s ); print $foundString; } __DATA__ apple banana pear peach grape orange
|
|---|