Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html><head><title>Exercise 3</title></head>
- <body bgcolor="red"><center><h2>Exercise 3</h2></center><p>
- Select your favourite colour from the list below: </p><p>
- <form name="form1">
- <select name="colours" onChange="document.bgColor=document.form1.colours.options[document.form1.colours.selectedIndex].value">
- <option value="red" style="background-color: red;">Red</option>
- <option value="blue" style="background-color: blue;">Blue</option>
- <option value="green" style="background-color: green;">Green</option>
- <option value="purple" style="background-color: purple;">Purple</option>
- <option value="yellow" style="background-color: yellow;">Yellow</option>
- </form>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement