JavaScript Reference/Javascript Properties/multiple
Содержание
"multiple" Example
<html>
<body>
Choose your Ice Creams<br>
<select name="mySelect" rows="10">
<option>A</option>
<option>B</option>
<option>C Chip</option>
<option>D</option>
</select>
<button onclick="mySelect.multiple=true;">Multiple</button>
<button onclick="mySelect.multiple=false;">Single</button>
</body>
</html>
"multiple" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |<select> |
+----------------+--------------------------------------------------------------+
"multiple" Possible Values
Possible Values
true
false.
"multiple" Syntax and Note
Note:
Read and write property.
Is <option> a multiple choice.
Syntax:
document.getElementById("selectID").multiple = value
document.all.selectID.multiple = value // IE only