W3C home > Mailing lists > Public > www-style@w3.org > October 2001

Re:Re: How is it possible to devise such a feeble system?

From: Andrew McFarland <andrew.mcfarland@unite.net>
Date: Wed, 24 Oct 2001 16:34:02 +0100
Message-Id: <>
To: www-style@w3.org
At 10:00 24/10/2001 -0400, Jesse McCarthy wrote:
>Using CSS how can I center the inner DIV
>or really the text within the inner DIV horizontally and vertically?

I'm pretty certain you can't.

What you are wanting to do is center the text vertically in the middle of 
the screen (or window). I don't think CSS `knows' what size the screen (or 
window) is. Setting the height to 100% is 100% of the height of the parent 
element, not the screen (or window).

If you can explain where you want to use the effect we may be able to 
suggest an alternative way of getting this to work for you.


Andrew McFarland
UNITE Solutions
Received on Wednesday, 24 October 2001 11:34:37 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:26:59 UTC