User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030827 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030827 If you define a table inside a cell of another table, text-align is not considered. The inner table is always left-aligned. Reproducible: Always Steps to Reproduce: 1. Load testcase Actual Results: Inner table in row 1 is left-aligned. WRONG Inner table in row 2 is centered. Correct Inner table in row 3 is left-aligned. WRONG Inner table in row 4 is right-aligned. Correct Text in row 5 is centered. Correct Expected Results: Inner table in row 1 and 2 should be centered. Inner table in row 3 and 4 should be right-aligned. Text in row 5 should be centered.
Text-align sets alignment for inline content of a block. A table is not an inline element. http://www.w3.org/TR/CSS21/text.html#propdef-text-align Set the table's left and right margin to auto to produce a centering effect. I think something similar produces a right alignment, but I haven't played with it. As it stands, bug is invalid.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 15 years ago
Resolution: --- → INVALID
margin-left:auto on the table will make it right aligned. Verified invalid.
Status: RESOLVED → VERIFIED
Reporter adding a strict doctype would show more clearly that the text text-align influences the text inside the table, in quirks mode the inheritance is broken at the the table level.
*** Bug 307272 has been marked as a duplicate of this bug. ***
You need to log in before you can comment on or make changes to this bug.