cross-browser minimum height


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



Copy this code and paste it in your HTML
  1. selector {
  2. height: 10em; /* min-height for IE. Must be declared above declaration for other browsers! */
  3. }
  4. selector:empty {
  5. min-height: 10em; /* min-height for browsers other than IE */
  6. height: auto !important; /* Override previously declared height for browsers other than IE */
  7. }
  8.  
  9. or even simpler:
  10.  
  11. selector {
  12. min-height: 10em; /* min-height for browsers other than IE */
  13. height: auto !important; /* Override declared height for browsers other than IE */
  14. height: 10em; /* min-height for IE */
  15. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.