Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Srict//EN"
- "http://www.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <title> Kangaroo </title>
- <script type="text/javascript">
- <!-- HIDE FROM INCOMPATIBLE BROWsERS
- var up_or_down;
- var begin;
- position = 0;
- horizontal = new Array(10);
- horizontal[0]=10;
- horizontal[1]=60;
- horizontal[2]=110;
- horizontal[3]=160;
- horizontal[4]=210;
- horizontal[5]=260;
- horizontal[6]=310;
- horizontal[7]=360;
- horizontal[8]=410;
- horizontal[9]=460;
- function hop() {
- if (up_or_down == "up") {
- document.getElementById("kangaroo").style.top = 60 + "px" ;
- up_or_down = "down";
- }
- else {
- document.getElementById("kangaroo").style.top = 120 + "px" ;
- up_or_down = "up";
- }
- document.getElementById("kangaroo").style.left = horizontal[position] +
- "px";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement