jquery/javascript wait for a function to complete
<p>I have script that performs from DOM manipulation to change the way a div looks. The way the application is, when the page loads, the div is rendered in its original state, the function manipulates the DIV. The problem is it renders the original div before rendering the changed div.</p>

<p>I tried:</p>

<pre><code>//Make div invisible

//Call function to change the DIV

//Make div visible
</code></pre>

<p>This does not work</p>
