title: Get parent node from XPATH descendant value
body: <p>I have a HTML structure that I am attempting to test using XPATH. The structure I'll looking at currently is something like: </p>
  
  <pre><code>&lt;div id="item_1" class="item-wrapper"&gt;
      &lt;div class="container item"&gt;
  
          &lt;div class="container-header"&gt;
              &lt;h2 id="title"&gt;test-title&lt;/h2&gt;
              &lt;h5 id="description"&gt;test-description&lt;/h5&gt;
          &lt;/div&gt;
  
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>There are a number of 'items' in my document, each with a unique ID. Using XPATH I want to 'get' the item_1 node from the value of the <code>title</code> id node ("test-title" in this case).</p>
  
  <p>I also want to do this in such a way that is not dependant on the node tag (<code>div</code>/<code>h2</code>/etc).</p>
  
  <p>I've been playing around with predicates, but I can't seem to get a solution that works. For example:</p>
  
  <pre><code>//*[@class="item-wrapper"][./*[@id="title"][text()="test-title"]] 
  </code></pre>
  
  <p>Thanks for any help!</p>