May 2009
M T W T F S S
« Feb   Jul »
 123
45678910
11121314151617
18192021222324
25262728293031

setTimeout() require qualification

21:55 on Tue 2009-05-26 by Leons Petrazickis Javascript

The two javascript functions above are very useful. The first one executes something after a set delay, and the second executes something at regular intervals. The syntax is very similar. var time = 2000; // 2 seconds window.setTimeout(function() { alert(‘Yay!’); }, time); window.setInterval(function() { alert(‘Woo!’); }, time);   Unfortunately, they weren’t working for me earlier. [...]