I have this string:
<li id="1">3431233</li>
<li id="2">fsdfdsfsdfdsfdsf</li>
<li id="3">abc</li>
<li id="4"> fdsf2342343</li>
<li id="5">123</li>
I want to replace only those lines containing abc or 123 with nothing (3rd and 5th in this case). My problem is that this regex wont work:
^<li>abc<\/li>
It replaces all lis. How can I only limit the replaceing to one certain line? The li differ from line to line and thats dynamic, I do not know how they will look (what classes and ids they might have.)
Thanks!