Previous Message
Next Message

Centering main body in all window sizes

Sent by Zoe M. Gillenwater on 22 March 2006 17:05

~davidLaakso wrote:
> Lee Sommerville wrote:
>> Could anyone please take the time to look at
>> please.
>> I want the main body of the site to be totally central
>> no matter what size the vierwers window is - at the
>> moment its stays central but far too near the top - i
>> want it completely central on all sides at all times?
> Lee,
> Possible, but difficult-- and not user friendly. To stay centered 
> vertically at 800 the height needs to be around 380px or less. Centering 
> vertically, at any screen resolution, is dependent on user top and 
> bottom window chrome. The height of the window varies wildly on my 
> browsers. Compensating for probable font zoom is really tough(zoom the 
> fonts on your current layout). Mostly one is better off taking advantage 
> of the vertical fluidity of the Web, and the vertical canvas, by /not/ 
> restricting height.
> That being said, this is one method for centering vertically and 
> horizontally: <>.

Note that if the window is shortened enough the top of the centered box 
gets cut off and cannot be scrolled to. I agree with David and Roger -- 
don't bother with vertical centering.


Zoe M. Gillenwater
Design Services Manager
UNC Highway Safety Research Center

css-discuss [EMAIL-REMOVED]]
IE7b2 testing hub --
List wiki/FAQ --
Supported by --
Previous Message
Next Message

Message thread: