[thelist] Second stupid CSS question of the evening

Gregory Wostrel info at gwcreative.com
Tue Oct 26 21:43:03 CDT 2004

On Oct 26, 2004, at 10:13pm, Christian wrote:

> So...how does one "center" an entire page in CSS?  I have already used 
> absolute positioning for certain DIVs - didn't really think it 
> through, perhaps - am I going to have to totally redo things?

I usually do this:
body {text-align: center;}
then make an enclosing <div> for the page and set left and right 
margins as auto.

You could also do the hack-y
<div align=center>
your content here

Gregory Wostrel

email: gw at gwcreative.com
web: http://www.gwcreative.com
tel: 401.286.9228

Communications and the Art of Simplicity

More information about the thelist mailing list