Home > Article > Web Front-end > Detailed explanation of how Html Select option makes default selection
Html Select The default selection is very simple. You only need to add the selected = selected attribute to an option to make it the default option. There is an example below. You may wish to refer to it.
Adding the selected = "selected" attribute to an option is the default option
For example:
The code is as follows:
<select id="isAudit" name="isAudit"> <option value="2">全部</option> <option value="1" selected = "selected">通过</option> <option value="0">未通过</option> </select>
Then "pass" is the default Selected.
For more detailed explanations on how to make the default selection of Html Select option, please pay attention to the PHP Chinese website for related articles!