[Solved] setting default value for option in html [closed]


In the given HTML code, you have given selected=”selected” for the “No” option. You need to give that in “Yes” option as follows.

<div class="col-sm-6 col-xs-12 col-md-6 col-lg-6">
    <label for="headoffice" class="col-sm-6 col-xs-7 col-md-4 col-lg-4 control-label">Head Office Member<sup class="text-red">*</sup></label>
    <div class="col-sm-6 col-xs-12 col-md-8 col-lg-8">                  
        <select class="multi-select" id="headoffice" name="headoffice" data-placeholder="Head Office Member">
            <option value=""></option>
            <option value="No" >No</option>
            <option value="Yes" selected="selected">Yes</option> 
        </select>
    </div>
</div> 

solved setting default value for option in html [closed]