[thelist] CSS max-width question.

Jonathan_A_McPherson at rl.gov Jonathan_A_McPherson at rl.gov
Mon Aug 12 11:27:05 CDT 2002


All,

I'm designing my first site of any considerable size since I first started
frequenting evolt/thelist, and I'm trying to get a table-free layout
going...

I want my site to be wrapped in a centered box no wider than 800px. (I'm
developing this on a 1600x1200 flatscreen, so I'm keenly aware of how
unreadable text gets when the lines become longer). I want the box to size
to less than 800px if the browser window gets smaller (i.e. if the user
doesn't like to browse fullscreen or has a lower-res display -- 800x600,
640x480).

"max-width: 800px;" works beautifully in Mozilla -- but in IE, it lets the
site expand indefinitely, allowing the lines of text to become almost
unreadably long in higher resolutions.

"width: 800px;" stops it from expanding, but also constrains it so that it
doesn't contract properly in lower resolutions.

"width: 75%;" makes it too wide for high resolutions and too narrow at low
resolutions.

Any suggestions? I'm sure this is a common quandary..

--
Jonathan McPherson, LMIT/SD&I
Software Engineer & Web Systems Analyst
email / jonathan_a_mcpherson at rl dot gov



More information about the thelist mailing list