title: jQuery show/hide - Question about the delay variable
body: <p>I'm using the following code to show a box when you mouseover a certain div and have set the delay on the fade out but is there some way of cancelling the fadeOut effect if the user goes back on to the div?</p>
  
  <pre><code>jQuery("#cart-box").hover(function() 
  {
      jQuery("#cart-container").fadeIn('fast');
  }, function( )
  {
      jQuery("#cart-container").delay(800).fadeOut('fast');
  });
  </code></pre>
  
  <p>Code for the divs</p>
  
  <pre><code>&lt;div class="cart-box" id="cart-box"&gt;&lt;a href="#"&gt;Cart&lt;/a&gt;&lt;div class="cart-container" id="cart-container"&gt;&lt;div class="cart-contents"&gt;contents&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;
  </code></pre>
  
  <p>Thinking about it I think it's probably a case me needing to stop the fadeIn function working if you go away from the div and go back.</p>
  
  <p>Any thoughts would be helpful as still very new to jQuery!</p>
  
  <p>On a side note what effect should I use to have the box expand from nothing to the height of the content instead of just fading in?</p>