Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function MoveMonday() {
- document.getElementById("col2").innerHTML = "<div id = \"box\"></div>";
- var elem = document.getElementById("box");
- var pos = 0;
- var id = setInterval(frame, 5);
- function frame() {
- if (pos == 350) {
- clearInterval(id);
- } else {
- pos++;
- elem.style.top = pos + 'px';
- }
- }
- Monday();
- }
- function Monday() {
- document.getElementById("box").innerHTML = "<p id = \"p1\">Monday</p>";
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement