I am trying to select certain objects by the Strings contained in them.
For example, if i defined an array of words, say like this:
var searchTerms = ["apple", "banana"];
How can i select among a series of identical objects those that contain one of those terms and remove the containing object from the DOM? As an example:
<section class="node_category">
<h3>orange</h3>
</section>
<section class="node_category">
<h3>apple</h3>
</section>
Thanks for your help!
*edited for clarity
h3removed, or its container too?