Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <title>Color Flasher</title>
- <script>
- After the user
- presses the Click for
- Story button, the
- text box displays a
- silly story.
- 66
- JavaScript Programming for the Absolute Beginner
- // Demonstrates use of the bgColor method
- document.bgColor = "red";
- alert("ready for another color?");
- document.bgColor = "orange";
- alert("ready for another color?");
- document.bgColor = "yellow";
- alert("ready for another color?");
- document.bgColor = "green";
- alert("ready for another color?");
- document.bgColor = "blue";
- alert("ready for another color?");
- document.bgColor = "indigo";
- alert("ready for another color?");
- document.bgColor = "violet";
- alert("ready for another color?");
- document.bgColor = "black";
- alert("ready for another color?");
- document.bgColor = "white";
- </script>
- </head>
- <body>
- <center><center>
- <h1>Color Flasher<br></h1>
- </center>
- <hr>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment