Re: table alignment; how to write

by Andrew McFarland <aamcf(at)>

 Date:  Thu, 14 Mar 2002 18:26:01 +0000
 To:  thewolves(at),
Deborah Shadovitz <debshadovitz(at)>
 Cc:  hwg-techniques(at)
 References:  mac
  todo: View Thread, Original
At 22:22 13/03/02 -0800, Larry Coats wrote:

>Using align="center" in the table tag is the poorest choice, because it's 
>only supported in NN 4+ and IE 4+ and of course is also deprecated:

This one has fewer unexpected side effects though. I must put together a 
page that demonstrates the weirdness that you can get with IE 6 and <div 

>Using a div tag with CSS text-align:center works in NN 4+ and IE 3+ and is 
>not deprecated.

But it shouldn't work. text-align applies to the line boxes within a block 
level element, not to block level elements themselves, and TABLE is block 

The correct way to center align block level elements with CSS is to make 
the left and right margins equal. Easier said than done, unfortunately.



HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA