iPad上缺少背景图片表格选择

时间:2014-02-07 20:47:18

标签: html css twitter-bootstrap twitter-bootstrap-3

我有一个选择表单控件,右侧显示自定义向下箭头图像。在iPad上查看时,此图像不显示。有谁知道我错过了什么?除了Bootstrap 3.0之外,这是我所拥有的HTML和CSS代码

<form name="scmarketer" id="scmarketer" action="" class="form-inline">
    <select class="form-control">
        <option>John Smith - Ontario CA</option>
        <option>Jane Smith - Ontario CA</option>
        <option>Brandon Smith - Ontario CA</option>
        <option>Terrell Owens - Ontario CA</option>
        <option>John Smith - Ontario CA</option>
        <option>Jane Smith - Ontario CA</option>
        <option>Brandon Smith - Ontario CA</option>
        <option>Terrell Owens - Ontario CA</option>
    </select>
    <button type="submit" class="btn btn-success">Save</button>
</form>

select.form-control {
    background-color: white;
    border-width: 1px;
    width: 70%;
    @media (max-width: 789px) {
        width:100%;
    }
    -webkit-appearance: none;
    -moz-appearance: none;
    text-indent: 0.01px;
    text-overflow: '';
    background-image: url('../images/dropdown.png');
    background-repeat: no-repeat;
    background-position: right center;
}

截图:

enter image description here enter image description here

2 个答案:

答案 0 :(得分:0)

您的背景图片网址设置为&#34; ../ images / dropdown.png&#34;所以它只适用于您的本地计算机。因此,您需要将其设置为图像的位置。

答案 1 :(得分:0)

尝试删除此内容:

@media (max-width: 789px) {
   width:100%;
}