check if a div which is inserted by javascript has loaded
<p>I have a page which loads in magento. Since i have to do some quick fix, I need to check if a DIV has loaded. The  is inserted using javascript.</p>

<p>div name: umm</p>

<p>using this: <a href="http://stackoverflow.com/a/4160706/1147634">http://stackoverflow.com/a/4160706/1147634</a></p>

<pre><code>var len = jQuery('#umm').append('&lt;a href="#"&gt;hi&lt;/a&gt;')
    .find('a')
    .load(function() {
        if( --len === 0) {
            alert('all are loaded');
        }
    }).length;
</code></pre>

<p>HTML inserted using javascript.</p>

<pre><code>&lt;input id="evtproducttype" type="hidden" value="activities"&gt;
&lt;input type="button" onclick="addInputGroup('evt_detail','evt_detaildhtmlgoodies_tabView1','evt_detailtabtitle');" value="+ Add Activity"&gt;
&lt;div id="umm"&gt;&lt;/div&gt;
&lt;div id="dynamicGroupControl"&gt;&lt;/div&gt;
</code></pre>

<p>I have to wait until this divs are loaded. </p>

<p>This doesn't work, and i my div is empty.  </p>
