I have an xml file that looks like this:
...
<e1>
<e2>
<e3>content1.1</e3>
<e3>content1.2</e3>
...
<e3>content1.n</e3>
</e2>
<e2>
<e3>content2.1</e3>
<e3>content2.2</e3>
...
<e3>content2.n</e3>
</e2>
...
</e1>
...
I need a regex that given the xml string (a bunch of e1 elements), would match the all e2 elements that have a child e3 element with content contentx. In other words, the regex would match all e2 elements (could have different e1 parents) where each of these elements has at least one e3 child who's contents equal contentx.