min/max-width fix for IE6


/ Published in: CSS
Save to your folder(s)

Javascript expression in css to allow for min/max widths. replaces the min-width, max-width that works for IE6.


Copy this code and paste it in your HTML
  1. #content {
  2. height: 75px;
  3. background-color: #000;
  4. color: #fff;
  5. width: expression(document.body.clientWidth < 742? "740px" : document.body.clientWidth > 1202? "1200px" : "auto");
  6. min-width: 740px;
  7. max-width: 1200px;
  8. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.