css - 选择 Safari Windows 上缺少的箭头

标签 css windows safari html-select

我使用以下类为选择添加了一些样式:

.form-fields select {
height: 24px;   
background: url(/Images/ui/input-bg.jpg) #FFF repeat-x;  
border: 1px solid #AAA;
}

这适用于所有浏览器,除了它会导致 Windows 上的 Safari 省略下拉箭头。 如果我同时注释掉 background 和 border 属性(并且仅注释掉两者),则箭头会恢复,但高度会在所有其他浏览器中被忽略。

我想保留这种样式,因为 Windows Safari 是少数,但我很想知道是否有适用于所有人的解决方案。

最佳答案

将它放在你的 CSS 中

*{
 -webkit-appearance: menulist;
}

关于css - 选择 Safari Windows 上缺少的箭头,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12498358/

相关文章:

css - 居中一个固定的div,div与图像大小相同

windows - php.ini 在哪里?

css - Angular2 - 为什么不会 :host grow vertically with its content in Safari?

php - 仅在 safari 和 chrome 中我的网页下方有奇怪的空间

html - Flexbox 网格 : two equal length rows, 顶行分成两列

javascript - WordPress 新闻如事件 slider

c++ - 直接显示 ISampleGrabber : samples are upside-down and color channels reverse

php - Ajax:跨域请求未使用 PHP 在 Safari IOS 中设置 cookie

javascript - Jquery 和制作封面 div 高于所有内容

windows - WINAPI,从菜单中删除弹出菜单