Disable jQuery effect on page refresh
<p><strong>Overview</strong></p>

<p>I have div#lead_form that SlideDown in 5 seconds after page loads. And in that div, I have a submit button. Everytime someone clicks submit, the form within #lead_form will validate the input fields and refresh the page. </p>

<p><strong>Issue</strong></p>

<p>Everytime the form validates, it refreshes the web page and the div#lead_form SlideDown  takes 5 seconds to slide in. What I want to do is, have a true false variable and check if the submit button has been clicked, if true, disable the div#lead_form SlideDown effect?</p>

<p><strong>My HTML</strong></p>

<pre><code>&lt;div id="lead_form"&gt;
&lt;div id="button"&gt;&lt;a href="#"&gt;&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p><strong>My jQuery</strong></p>

<pre><code>$(document).ready(function() {
 $("#lead_form").hide(0).delay(4000).slideDown(5000);
});
</code></pre>

<p><strong>Findings</strong></p>

<p><a href="http://stackoverflow.com/questions/1712589/jquery-how-to-sequentially-run-an-animation-only-once-after-animation-on-a">This is not exactly what I'm after, but similar?</a></p>
