jquery - Check if element is in the fadeIn or fadeOut state ('action') -
i need stop(cancel) current .fadein(5000) , start same fadein beginning, once button clicked (otherwise next fadein start after 5000). how can check, if div actively fading , how can cancel (i assume .hide())?
use .stop()
. don't need test if fadein
running, if not, stop
has not effect.
you still have hide though. like:
$('selector').stop(true).hide().fadein(5000);
Comments
Post a Comment