Create a selection menu with this array:
$types = [ '' => 'select a type', 'one' => 'type one', 'a' => 'type a' ];
And the rules for validation:
$rules = ['type' => 'required'];
The first key of $ types is an empty string. It will be displayed as follows:
<option value=''>select a type</option>
When validating, the correct rule will not be validated.
Assuming all parameters in the selection menu are valid parameters.
source share