Reputation: 862
IE7 doesn't support :last-child pseudo selector. I am thinking of explicitly adding a class name to denote it as the last element but not sure how to select this element inside a css file. Anyone have any ideas on how to do this ?
Upvotes: 6
Views: 8229
Reputation: 45731
One extra thing to note about multiple classnames is that IE6 can not handle them properly. It will only consider the last classname in the list:
.class1.class2 {color:red} => .class2 in IE6
Upvotes: 0
Reputation: 12230
If you have
<div class="element"/>
<div class="element last"/>
You can just do
div.element
{
// styles effect both divs
}
div.last
{
// style will only effect the second element and overides because lower in the css
}
Upvotes: 3