How to show first select option as a default using html [closed]

  html, php
           <select id="comitem" name="comitem" onChange="formsearch.submit();">
            <option>Select Category</option>
            <option value="all" <?php if ($vCat=="all") { echo "selected"; } ?>>All </option>
            <option value="black" <?php if ($vCat=="black") { echo "selected"; } ?>>Black</option>
            <option value="red" <?php if ($vCat=="red") { echo "selected"; } ?>>Red</option>
            <option value="yellow" <?php if ($vCat=="yellow") { echo "selected"; } ?>>Yellow</option>                
            </select>

when publish dropdown display last option (Yellow), i want display Select Category. anyone can help me.

Source: Ask PHP

LEAVE A COMMENT