<html>
<head>
<script language="JavaScript">
<!--
function getName(){
alert("The name of this select box is " + document.myForm.elements[0].name);
}
-->
</script>
</head>
<body>
<form name="myForm">
<select name="mySelect" multiple>
<option value=A>AA</option>
<option value=B>BB</option>
<option value=C>CC</option>
<option value=D>DD</option>
</select>
<input type=BUTTON value="Get Name" name="myButton" onClick='getName()'>
</form>
</body>
</html>
|