How to animate jquery effects simultaneously
for example I have 2 jquery effects and 3 object:
$('.test1').fad开发者_Python百科eIn();
$('.test2').fadeOut();
$('.test3').fadeOut();
when .test1 fades in .test2 and .test3 must fade out simultaneously. how can I do it without extra plugin and without opacity animation?
you can use the callback for achieving the same
$('.test1').fadeIn('slow', function() {
$('.test2').fadeOut();
$('.test3').fadeOut();
});
$(".test1").fadeIn("fast",function(){$(".test2,.test3").fadeOut()});
精彩评论