What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » JS help

JS help
Author: Message:
Stigmata
Veteran Member
*****



Posts: 3520
Reputation: 45
21 / Other / Flag
Joined: Jul 2003
RE: JS help
code:
<SCRIPT LANGUAGE = "JavaScript">
<!--
var secs
var timerID = null
var timerRunning = false
var delay = 1000

function InitializeTimer()
{
    // Set the length of the timer, in seconds
    secs = 10
    StopTheClock()
    StartTheTimer()
}

function StopTheClock()
{
    if(timerRunning)
        clearTimeout(timerID)
    timerRunning = false
}

function StartTheTimer()
{
    if (secs==0)
    {
        StopTheClock()
        alert("You have just wasted 10 seconds of your life.")
window.close
    }
    else
    {
        self.status = secs
        secs = secs - 1
        timerRunning = true
        timerID = self.setTimeout("StartTheTimer()", delay)
    }
}
//-->
</SCRIPT>


then

code:
<body onLoad="InitializeTimer()">

http://www.mcfedries.com/JavaScript/timer.asp

just a edited version of some code i found :)

This post was edited on 10-13-2005 at 06:32 PM by Stigmata.
10-13-2005 06:31 PM
Profile PM Web Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
JS help - by Supersonicdarky on 10-13-2005 at 06:26 PM
RE: JS help - by Stigmata on 10-13-2005 at 06:31 PM
RE: JS help - by -dt- on 10-13-2005 at 06:45 PM
RE: JS help - by Supersonicdarky on 10-13-2005 at 07:15 PM
RE: JS help - by -dt- on 10-13-2005 at 07:17 PM
RE: JS help - by Supersonicdarky on 10-13-2005 at 07:21 PM
RE: JS help - by Plik on 10-13-2005 at 07:24 PM
RE: JS help - by Supersonicdarky on 10-13-2005 at 07:27 PM
RE: JS help - by -dt- on 10-13-2005 at 07:29 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On