0
<html>
<script>
function startEQ()
{
quake=5;
parent.moveBy(0,quake);
parent.moveBy(0,-quake);
parent.moveBy(quake,0);
parent.moveBy(-quake,0);
timer=setTimeout("startEQ()",10);
}
function stopEQ()
{
clearTimeout(timer);
}
</script>
</head>
<body>


DEMO IT HERE
<form>
<input type="button" onclick="startEQ()" value="Start an earthquake">
<input type="button" onclick="stopEQ()" value="Stop the earthquake">
</form>
</body>
</html>
1
Contributor
2
Replies
3
Views
6 Years
Discussion Span
Last Post by murtazamzk
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.