【问题标题】:Select Option Font size in not changing选择选项字体大小不变
【发布时间】:2020-09-24 08:54:49
【问题描述】:

我已经尝试过将它放在课堂上,然后通过访问课堂进行编辑 我也尝试过 optgrp,但也没有用。

请看下面我的代码

<style>
select {
    width: 300px; 
    margin: 10px; 

font-size:10px;
border:0; 
-webkit-appearance: none;
}

select:focus {
    min-width: 300px;
    width: 300px;
}       

</style>
<label for="Department">Choose a Department:</label>
<select name="Select Department" onchange="location = this.value;">

<option value="#">All Departments</option>
<option value="#">Cardiology</option>
<option value="#">Plastic, Cosmatic & Reconstrustive Surgery</option>
<option value="#">Dentistry</option>


</select>

【问题讨论】:

    标签: html fonts option


    【解决方案1】:

    试试这个..

    <style>
    .drpdwn-style{
        width: 300px; 
        margin: 10px; 
    
    font-size:10px;
    border:0; 
    -webkit-appearance: none;
    }  
    </style>
    <label for="Department">Choose a Department:</label>
    <select name="Select Department" class= "drpdwn-style" onchange="location = this.value;">
    <option value="#">All Departments</option>
    <option value="#">Cardiology</option>
    <option value="#">Plastic, Cosmatic & Reconstrustive Surgery</option>
    <option value="#">Dentistry</option>
    </select>

    【讨论】:

    猜你喜欢
    • 2018-03-13
    • 2011-07-17
    • 1970-01-01
    • 1970-01-01
    • 2020-10-29
    • 2018-07-30
    • 2013-06-29
    • 2013-06-17
    • 1970-01-01
    相关资源
    最近更新 更多