How can I wrap the entire page contents in a div using jquery
<p>Here is my code.</p>

<pre><code>$(function(){
    $("body").prepend('&lt;div id="loading"&gt;&lt;span id="pagename"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div id="fade_wrapper"&gt;');
    $("body").append('&lt;/div&gt; &lt;!-- closing #fade_wrapper --&gt;');
});
</code></pre>

<p>The problem is that chrome auto closes the open <code>&lt;div id="fade_wrapper"&gt;</code> so that the HTML looks like this:</p>

<pre><code>&lt;div id="loading"&gt;&lt;span id="pagename"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div id="fade_wrapper"&gt;&lt;/div&gt;
</code></pre>

<p>That closing DIV in the second code shouldn't be there. How can I wrap the entire page contents in a div using jquery?</p>
