Monday, March 21, 2011

Timers are used in web page. using timer we can execute any function or object after a set of time.

Timer Function in JavaScript
<script type="text/javascript">
function remind(msg1) {
var msg = "This is a reminder after " + msg1 +" Secs";
<body >
<input type=radio name=rm value=no checked>No reminder
<input type=radio name=rm value=5000 OnClick="mytime=setTimeout('remind(1)',1000)">After 1 Secs
<input type=radio name=rm value=5000 OnClick="mytime=setTimeout('remind(2)',2000)">After 2 Secs
<input type=radio name=rm value=5000 OnClick="mytime=setTimeout('remind(5)',5000)">After 5 Secs

No comments:

Post a Comment

rathoddhirendra.blogspot.com-Google pagerank and Worth