Can I use addClass on information stored in an HTML string?
<p>I have a string that for example looks like this.</p>

<pre><code>var html = '&lt;div class="templatemo_post_text grid-85"&gt;
&lt;div id="wmd-preview"&gt;&lt;h2&gt;Skriv något!&lt;/h2&gt;
&lt;p&gt;Lorem ipsum&lt;/p&gt;&lt;/div&gt;
&lt;div class="templatemo_post_footer"&gt;
&lt;div class="templatemo_post_on"&gt;
&lt;span class="orange"&gt;Skrivet den&lt;/span&gt; 3 Mar 2013&lt;/div&gt;
&lt;div class="templatemo_post_comment"&gt;
&lt;a href="#"&gt;Inlägg nummer &lt;/a&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;';
</code></pre>

<p>Can I use the .addClass() in some way to add a class to the id=wmd-preview?<br>
Actually my question goes for all javascripting to modify existing variables. One other thing I would like to do is to replace the whole  tag with a new one.</p>

<p>Thanks.</p>
