[web] Problem with some CSS in IE
I'm having a bit of trouble with some CSS, it works in Opera & Firefox but not in IE (surprise surprise, althought I've not tried IE7).
This CSS code looks something like this...
/* -----------------------*/
li {
background-color: black; /* All list elements in IE have this style */
}
ul > li {
background-color: red;
}
ul > li + li {
background-color: orange;
}
ul > li + li + li {
background-color: yellow;
}
/* etc... */
/* -----------------------*/
So I'm trying to change the style of each list item. Any ideas on getting this to work in IE?
Simply, IE6 doesn't support > or + selectors.
As for getting it to work under old versions of IE, I can't suggest anything beyond marking each list item with a different class or specifiying the colour inline. You'd hope everyone was using 7, but there are still those at businesses or those on Windows 2000 stuck on version 6.
As for getting it to work under old versions of IE, I can't suggest anything beyond marking each list item with a different class or specifiying the colour inline. You'd hope everyone was using 7, but there are still those at businesses or those on Windows 2000 stuck on version 6.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement