This question already has an answer here:
- How to style a <select> dropdown with only CSS? 24 answers
I am working on a project where i need to style a selectbox. I can easy style the selectbox to match the psd, but when it comes to the dropdown area, its driving me nuts.
How is that possible? I have tryed with adding a overlay to the dropdown area with som css stuff, but i can't get it to work well.
The code for selectbox:
#sidebar select{
background: transparent;
width:148px;
height:31px;
border:0;
border-radius:3px;
line-height:1;
-webkit-appearance: none;
outline:none;
color:silver;
padding: 0px 0px 0px 10px;
font-style: italic;
cursor: pointer;
}
.styled-select{
width: 150px;
height: 30px;
overflow: hidden;
background: url('../images/icons/selectbox.png') no-repeat right;
border:0;
}
<div class="styled-select">
<select class="selectbox">
<option value="">Hollaws</option>
<option value="">Hollaws</option>
<option value="">Hollaws</option>
</select>
</div>
A small fiddle for example is provided here