How can I know when a certain iframe gets removed from a page
<p>Let's say I have an iframe on a HTML page:</p>

<pre><code>&lt;iframe src="/script.php"&gt;&lt;/frame&gt;
</code></pre>

<p>The iframe is inside a modal box window (I'm using a jQuery plugin for modal window: <a href="http://opensource.steffenhollstein.de/templates/modalbox/" rel="nofollow">http://opensource.steffenhollstein.de/templates/modalbox/</a>).</p>

<p>When the modal box gets closed, the iframe inside it is removed from the page's HTML with jQuery remove() method.</p>

<p>How can I notice that the iframe has been removed and execute some javascript code? Basically what I want is to refresh the page once the modal box is closed. This is the close method for the modal box plugin:</p>

<pre><code>jQuery.fn.modalBox.close = function(settings){

    // merge the plugin defaults with custom options
    settings = jQuery.extend({}, jQuery.fn.modalBox.defaults, settings);

    if( settings.setFaderLayer &amp;&amp; settings.setModalboxContainer ){
        jQuery(settings.setFaderLayer).remove();
        jQuery(settings.setModalboxContainer).remove();
        jQuery("iframe.modalBoxIe6layerfix").remove();
    }
};
</code></pre>
