Page 2 of 2

div and css big problem

Posted: Sun Jun 26, 2011 3:23 pm
by Johnherpes
As SoopahMan said, you need to apply centering in two ways when using CSS. Furthermore, for IE if you say something like <div align=center>, that centers everything inside the div so you then need to add align=left inside the div.

But back to basic centering. For objects like tables the correct method is to apply margin-left:auto; margin-right:auto; to the object being centered. However, this doesnt work in IE so you also need to apply either
or text-align:center; around the table being centered.

Code: