Home >Web Front-end >HTML Tutorial >How to set the default selection for Select option in Html
This time I will show you how to set the default selection for the Select option in Html. What are the precautions for setting the default selection for the Select option in Html? The following is a practical case. Let’s take a look. Add selected = "selected" to an option
Attribute
<select id="isAudit" name="isAudit"> <option value="2">全部</option> <option value="1" selected = "selected">通过</option> <option value="0">未通过</option> </select>
Other
related articles!How to set overflow when the html table is relatively wide
htmlHow to add attributes using style example
htmlHow to use the title attribute to display text where the mouse is hovering
htmlHow to use a hyperlink to control when opening a new window Its properties
The above is the detailed content of How to set the default selection for Select option in Html. For more information, please follow other related articles on the PHP Chinese website!