title: How to change HTML attributes in a raw string with Jquery or Javascript?
body: <p>I want to take a bunch of anchor tags and make sure that they all open in a new tab.</p>
  <p>I know I should do something like this <code>$('a').attr('target', '_blank');</code> but the catch is that the HTML I am trying to modify is in a string variable.</p>
  <p>See example:</p>
  <p>I have a bunch of raw HTML in a string like this:</p>
  <pre><code>var rawHTML = 'Hello there, &lt;a href=&quot;http://www.google.com&quot;&gt;this&lt;/a&gt; is a link.'
  </code></pre>
  <p>How can I convert that to be something like this:</p>
  <pre><code>processedHTML = 'Hello there, &lt;a href=&quot;http://www.google.com&quot; target=&quot;_blank&quot;&gt;this&lt;/a&gt; is a link.'
  </code></pre>