+ 1

[SOLVED] Can i put a setInterval method here? Please tell me if i can put it and where

$(function() { var div = $("div"); div.animate({opacity: 1}); div.animate({height: '+=100px', width: '+=100px', top: '+=100px'}, 500); div.animate({height: '-=100px', width: '-=100px', left: '+=100px'}, 500); div.animate({height: '+=100px', width: '+=100px', top: '-=100px'}, 500); div.animate({height: '-=100px', width: '-=100px', left: '-=100px'}, 500); div.animate({opacity: 0.5}); });

23rd Jan 2021, 12:40 PM
JustSteve
1 Odpowiedź
0
You just asked the question and already labeled it as unsolved. !? If you know how setInterval works you wudn't be asking this question, so first go and read about it. If you analyse code you will see it is assigning different values everytime, no way setInterval can be used here.
23rd Jan 2021, 1:09 PM
Abhay
Abhay - avatar