当前位置: 代码迷 >> 综合 >> select框默认样式去除(自定义箭头小图标)
  详细解决方案

select框默认样式去除(自定义箭头小图标)

热度:9   发布时间:2024-01-30 13:00:18.0
CSS代码/*清除ie的默认选择框样式清除,隐藏下拉箭头*/select::-ms-expand { display: none; }          .info-select{width: 12%;margin-left: 64%;border: none;outline: none;/*将默认的select选择框样式清除*/appearance:none;-moz-appearance:none;-webkit-appearance:none;-ms-appearance:none;/*在选择框的最右侧中间显示小箭头图片*/background: url(../img/arrow.png) no-repeat right center transparent /size;     }HTML代码<select class="info-select"><option selected="selected">北京</option><option>上海</option></select>

background连写方法

  相关解决方案