HTML <select> name attribute
Definition and Usage
name
The attribute specifies the name of the dropdown list.
name
The attribute is used to reference an element in JavaScript, or to reference form data after the form is submitted.
Example
Dropdown list with name attribute:
<label for="cars">Please select a car brand:</label> <select name="cars" id="cars"> <option value="volvo">Volvo</option> <option value="saab">Saab</option> <option value="opel">Opel</option> <option value="audi">Audi</option> </select>
Syntax
<select name="text">
Attribute Value
Value | Description |
---|---|
text | ກໍານົດຊື່ບັນຊີຂອງວາງລົງ |
Browser Support
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Support | Support | Support | Support | Support |