Post Reply 
How to halt the match after the first instance
Aug. 09, 2019, 02:59 AM
Post: #1
How to halt the match after the first instance
.... without using the byte limit that is.

If the filter is something like:

Code:
<li class="user">*(jason|julia|jeff)*
</div>
</li>

and it encounters code like this

Code:
<li class="user">
<div title="erika"
<img src="pic.jpg">
</div>
</li>

<li class="user">
<div title="jason"
<img src="pic.jpg">
</div>
</li>

The match will include both <li> elements instead of just the second one. Is there a way to make it stop searching after the first "</div></li>" so that it will leave the first element alone, but match/replace the second, then continue doing the same for the rest of the page? Assume that other <li> elements exist which are longer, requiring a byte limit bigger than the examples above.
Add Thank You Quote this message in a reply
Post Reply 


Messages In This Thread
How to halt the match after the first instance - zoltan - Aug. 09, 2019 02:59 AM

Forum Jump: