How to remove the arrow from a select element in Firefox

后端 未结 30 1362
北恋
北恋 2020-11-22 15:58

I\'m trying to style a select element using CSS3. I\'m getting the results I desire in WebKit (Chrome / Safari), but Firefox isn\'t playing nicely (I\'m not ev

30条回答
  •  太阳男子
    2020-11-22 16:46

    The trick that works for me is to make select width more than 100% and apply overflow:hidden

    select {
        overflow:hidden;
        width: 120%;
    }
    

    This is the only way right now to hide dropdown arrow in FF.

    BTW. if you want beautiful dropdowns use http://harvesthq.github.com/chosen/

提交回复
热议问题