Jquery, FadeIn before unload
<p>I'm trying to accomplish a transition effect if you will. On doc ready div fades out, the problem im having is when a visitor navigates away from the page (or .unload) I want the div to fade back in.</p>

<pre><code>$(document).ready(function(){

    $('#overlay').fadeOut(2000, 'easeOutQuad');

});


$(window).beforeunload(function() {

    $('#overlay').fadeIn(2000, 'easeOutQuad');

});
</code></pre>
