English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Das value-Attribut legt fest, welchen Wert der Server beim Absenden des Formulars erhalten soll. Beginnt mit <option> und endet mit <// Inhalt zwischen den <option>-Tags ist das, was der Browser im Dropdown-Menü anzeigt.
HTML-Liste im Formular:
<!DOCTYPE html> <html> <head> <title>HTML:<option value=" - 基础教程网(oldtoolbag.com)</title> </head> <body> <form action="action_page.php"> <select name="language"> <option value="PHP" disabled>PHP</option> <option value="HTML">HTML</option> <option value="C++">C++</option> <option value="GOLANG">GOLANG</option> <option value="JAVA">JAVA</option> </select> <input type="submit" value="Submit"> </form> </body> </html>Test to see ‹/›
IEFirefoxOperaChromeSafari
All major browsers support the value attribute.
The value attribute specifies the value to be sent to the server when the form is submitted.
Start with <option> and end with </ The content between the <option> and </option> tags is the content that the browser will display in the dropdown list. However, the value of the value attribute is the value that will be sent to the server when the form is submitted.
Note: If the value attribute is not specified, the content is passed as the value.
None.
<option value="value">
Value | Description |
---|---|
value | Value sent to the server. |