in reply to Re: Lookahead assertion confusion
in thread Lookahead assertion confusion
with(?!.*<p>.*)
.(?!.*<p>)
But I think you are missing the point of the assertion, as $1 now captures the second <p> in your string, and not the first, as the original had intended, which might not be important in this case, but might be in your understanding of what how better to approach regex problems) in which case:
or /[^(?:<p>)]+?(<p> )(.+)(features\: <ul>)/i works just as well. just because TMTOWTDI, doesn't mean that you have to use every tool in the toolshed to get to result when a simple screwdriver would have sufficed (pardon the expression)./<p>.*?(<p> )(.+)(features\: <ul>)/i
-enlil
|
---|