I have a string with some markup which looks like this:
The quick brown <a href="www.fox.org">fox</a> jumped over the lazy <a href="entry://id=6000009">dog</a> <img src="dog.png" />.
I'm trying to strip away everything except the anchor elements with "entry://id=" inside. Thus the desired output from the above example would be:
The quick brown fox jumped over the lazy <a href="entry://id=6000009">dog</a>.
Writing this match, the closest I've come so far is:
<.*?>!<a href=\"entry://id=\\d+\">.*?<\\/a>
But I can't figure out why this doesn't work. Any help (apart from the "why don't you use a parser" :) would be greatly appreciated!