I'm developing a site where I want the widths to stretch and adapt to different screen and windowsizes.... but I would like it to stretch up to a max width. Even if the screenresolution is much higher the width of my 'white paper' should stop stretching with this max set width of my choice. The reason I want this is because the page doesn't look as nice in higher resolutions, too much white in between.
Is there a way to do this? I'm using XHTML and CSS, no tables at all.
You can see it here... http://www.lonesomepine.se
unfortunately there isn't. this is because XHTML and CSS and not "programming languages" and there for cannot be set with conditions like an if statement.
btw, i like the set up of your XHTML and CSS, very clean, very nice
You may be able to do this in CSS, the max-width property can set an upper bound on the width of an element. It's a CSS2 property which means that it probably won't work on a lot of browsers unfortunately.
Worked great!! ..at least in Mozilla 1.1, not IE 6, but I guess it will eventually. =) Just one thing, when it hit the max, the page wasn't centered any more, is it just a bug or?