Reputation: 55
css:
.combobox{
color: black;
border-width: 1px;
border-color: #DB6E6E;
}
html:
<select class = "combobox">
<option>1</option>
<option>2</option>
<option>3</option>
</select>
"combobox" properties are fine with all browsers except ie7 (border isn't red). I tried to add this combo to a div which i gave the class properties but nothing change. how can i fix it?
Upvotes: 0
Views: 39
Reputation: 85545
You're not adding border-style:
.combobox{
color: black;
border-width: 1px;
border-color: #DB6E6E;
border-style: solid;/*must be added to make it work*/
}
In shorter form, you can use border
property:
.combobox{
color: black;
border: 1px solid #DB6E6E;
}
Also, in your html, don't separate the class attribute and it's value:
<select class = "combobox">
<!----------^^ ^^ ------use class="combobox" ----->
Upvotes: 2