jQuery: take existing HTML, modify one node, then reinject
<p>I have a blob of HTML that I'm retrieving using simple jQuery selectors, something like the following:</p>

<pre><code>&lt;div id="stuff"&gt;
 &lt;ul&gt; 
   &lt;li&gt;some&lt;/li&gt;
   &lt;li class="ninja"&gt;stuff&lt;/li&gt;
 &lt;/ul&gt;
&lt;/div&gt;
</code></pre>

<p>I'm basically doing:</p>

<pre><code>var myblock = $("#stuff").html();
</code></pre>

<p>now I want to inject an additional li element to the bottom of that li list with very similar attributes to the li above it, but i want to change the class ninja to class samurai. </p>

<p>What's the best way of going about that with jQuery?</p>
