Tutorial Perform Function At Timed Intervals
by Unknown in javascript , Tutorial 0
Perform a function every one second:
function myFunction() {
// do something
}
var int = setInterval(myFunction, 1000);
Cancel it:
clearInterval(int);
Pass variables when calling custom function:
setInterval(function(){ doMove(panelWidth, tooFar); }, delayLength);