I want to set all non-multiple select tags that are not multiple to be italic, I want this not to be set to the multiple select tags. So far I’ve wrote this css:
select
{
font-style:italic;
}
select[multiple="multiple"]
{
font-style:normal;
}
This works in any normal browser but does not work in internet explorer 8 (and 9, but that is less important). How can i get this to work in internet explorer 8?
Add the following at the very start of the HTML document:
This prevents IE from going to Quirks Mode where it does not recognize many CSS features, such as attribute selectors, among other things.
In addition, consider simplifying the selector to
so that it will also apply to syntactic markup variants like
<select multiple>.