Count 4 Close Window

[Total: 0    Average: 0/5]

This will use the timeout method to count 4 seconds – then try to close the window.

Body Code:

<SCRIPT LANGUAGE="JavaScript">
function closeWin(){
        window.close()
}
function timer(){
        timerID = setTimeout("closeWin()", 4000)
}

</SCRIPT>
Window will close in 4 sec (or at least it will ask you)
<script>
timer();
</script>

Times Viewed: 0

Leave a Reply

Your email address will not be published. Required fields are marked *