Created
March 23, 2011 16:24
-
-
Save jookyboi/883383 to your computer and use it in GitHub Desktop.
Max width css property for IE
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* From http://perishablepress.com/press/2007/01/16/maximum-and-minimum-height-and-width-in-internet-explorer/ */ | |
* html div#division { | |
width: expression( document.body.clientWidth > 776 ? "777px" : "auto" ); /* sets max-width for IE */ | |
} | |
div#division { | |
max-width: 777px; /* this sets the max-width value for all standards-compliant browsers */ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment