自定义下拉不工作IE和Firefox

时间:2013-11-06 11:16:35

标签: html css html5 firefox

我有一个自定义img用于我的下拉选项菜单,我尝试了其他浏览器,如Internet Explorer和FireFox ......

我的代码:

textarea {
    background: #9d9d9d;
    color: #000000;
    width: 90%;
    padding: 5px;
    border-radius:5px;
    -moz-border-radius:5px;
    -webkit-border-radius:5px;
}
.styled-select {
   width: 88%;
   height: 30px;
   overflow: hidden;
   background: url('../img/down.png') no-repeat right #9d9d9d;
   border: 1px solid #ccc;
   border-radius:5px;
   -moz-border-radius:5px;
   -webkit-border-radius:5px;
}

This is the drop down on firefox

This is the Drop Down on Internet Explorer

首先Img用于Firefox,第二个img用于Internet Explorer

1 个答案:

答案 0 :(得分:1)

对于I.E:

select::-ms-expand
{  
 display: none;
}

对于Firefox:

.select
{
-moz-appearance: none; 
 appearance: none;    
 text-overflow: ''; 
}
相关问题