CSS min-height in IE6

Ok - so this isn't Drupal related, but it is a really cool trick! For those folks who know CSS, Internet Explorer 6 is a HUGE PAIN IN THE ***. Ahem. Anyway, IE6 doesn't support min/max height or width. This is really frustrating if you have a design that you'd like to be somewhat flexible, yet doesn't look good below/above a certain height/width.

Until now, I figured the only good solution was to use conditional comments to include a stylesheet specifically for earlier versions of IE that just sets everything to a static width or height.

Then I found this little thing:


#container {
height: expression(this.offsetHeight <= 270 ? "270px" : "auto");
}

What's that you say? JAVASCRIPT?? In a CSS document? Yup. :) And it worked.

Oh - and as a separate reminder to self - self, if you encounter missing background images, lost content, or weird floating divs - remember to add zoom: 1; to the parent element. Thanks.