IE7 does not support: last-child pseudo-selector. I am thinking of explicitly adding the class name to designate it as the last element, but not sure how to select this element inside the css file. Anyone have any ideas on how to do this?
.class1.class2 {color:red}
and
<div class="class1 class2"></div>
or install IE7-js and: last-child will just work.
If you
<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 }
Another thing worth noting about several classes is that IE6 cannot handle them correctly. It will consider only the last class name in the list:
.class1.class2 {color:red} => .class2 in IE6