CSS, overwrite height of all select dropdowns?

后端 未结 7 846
夕颜
夕颜 2021-01-05 16:44

how would i reference, so i could overwrite, all of the select boxes so i can overwrite the default height? I\'m familiar when i create elements using a class, but im unsure

相关标签:
7条回答
  • 2021-01-05 17:17

    The best way is to give a class on your select element. <select name="nameforyourselect" class="myclass"></select>

    Then on your css set the height, for example .myclass{height:30px;} this will give height 30px on all elements with class name myclass. I suggest you this way, because you may wish to create another select element with another height. So you just set other class on it and define it on your css.

    0 讨论(0)
提交回复
热议问题