I've got something like this:
<p id="tire">I need new tires for my car</p>
I'm trying to write something that would highlight word(s) that I assign, but NOT the stuff that is considered a tag. For example, if I want to highlight "tire", I'd theoretically see:
<p id="tire">I need new <strong>tire</strong>s for my car</p>
But unfortunately, I see:
<p id="<strong>tire</strong>">I need new <strong>tire</strong>s for my car</p>
I'm using just a simple replaceAll(oldWord, newFormat). Is there a library that can help? I am using jsoup to grab the HTML I would be searching through.