Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Jquery fade/toggle only works on first click… Re: Jquery fade/toggle only works on first click…

#83181
Mottie
Member

I think you need to move the callback to the slideToggle function, but I don’t know what your HTML looks like… so try this:

$(document).ready(function(){
$(".btn-slide").click(function(){
$("#panel").slideToggle(600, function() {
$('.one-third').fadeIn(1000);
});
$(this).toggleClass("active");
return false;
});
});