title: How to check if a DOM element contains a string
body: <p>Is there a way to see whether a string is contained within an element? Specifically a link?</p>
  
  <p>For example:</p>
  
  <pre><code>&lt;a href="#"&gt;Some text foo_string more text&lt;/a&gt;
  </code></pre>
  
  <p>will return "a" as the element. jQuery or PHP - doesn't matter. Thank you!</p>
  
  <p><strong>Clarification:</strong></p>
  
  <p>What I want to know  is the element that contains foo_string. NOT whether an element contains the string.</p>