Wednesday, May 25, 2011

timer() method

The timer() method executes a script after a specific number of milliseconds.

Browser support: all
TheMadScript Version: 2.0.0

Syntax: timer(milliseconds,result);


The syntax below will set a timer for 4500 milliseconds (4.5 seconds) and then display a welcome message in an alert box:


timer(4500,"box_alert('Welcome! This box displayed for 4.5 seconds!')");

No comments:

Post a Comment