in reply to Matching set of paragraph tags with string inside.
I try to avoid getting too tricky with regexes, because I am a bear of little brain. I'd break the string up then inspect it in pieces, perhaps like this:
my @arr = split /<\/p>/, $string; @matches = grep { /\[tab\]/ } @arr;
one extra line but much easier for me. If I was concerned about it looking neat, I'd put the code inside a subroutine called match_tabs().
___________________
Jeremy
I didn't believe in evil until I dated it.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Matching set of paragraph tags with string inside.
by Roy Johnson (Monsignor) on Feb 08, 2008 at 21:26 UTC | |
by jepri (Parson) on Feb 09, 2008 at 00:11 UTC | |
by Roy Johnson (Monsignor) on Feb 11, 2008 at 18:44 UTC | |
Re^2: Matching set of paragraph tags with string inside.
by the_0ne (Pilgrim) on Feb 08, 2008 at 21:26 UTC |
In Section
Seekers of Perl Wisdom