<HTML>
<HEAD>
<TITLE>Color Changer 2</TITLE>
<SCRIPT LANGUAGE="JavaScript">
function seeColor(form) {
var newColor = (form.colorsList.options[form.colorsList.selectedIndex].value);
document.bgColor = newColor;
}
</SCRIPT>
</HEAD>
<BODY>
<FORM>
<P>Choose a background color:
<SELECT NAME="colorsList">
<OPTION SELECTED VALUE="cornflowerblue">Cornflower Blue
<OPTION VALUE="darksalmon">A
<OPTION VALUE="lightgoldenrodyellow">B
<OPTION VALUE="seagreen">C
</SELECT></P>
<P><INPUT TYPE="button" VALUE="Change It" onClick="seeColor(this.form)"></P>
</FORM>
</BODY>
</HTML>
|