Bhupinder kumar Bhupinder kumar - 1 month ago 15
CSS Question

How to give the padding for option with css only

How we can give the padding for option in select box or height ?
like this :

<select>
<option value="volvo">Volvo</option>
<option value="saab">Saab</option>
<option value="vw">VW</option>
<option value="audi" selected>Audi</option>
</select>

Answer

Yes you cannot add custom style to Select input element since they are render by User agents (Browsers). You can use some plugin to render select element so that you can customize as you wish.