Closed Bug 278918 Opened 20 years ago Closed 20 years ago

Moz 1.8a6 Table content centers when only table itself should be centered

Categories

(Core :: Layout, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: gorham, Unassigned)

References

()

Details

(Keywords: qawanted, testcase)

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8a6) Gecko/20050111
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8a6) Gecko/20050111

<body>	
  <center>
   <table width="100%"  border="0" cellpadding="0" cellspacing="0">
    <tr class="oscms_header">
     .....
Entire content within the table is centered when it is not supposed to be.

The content rendered correctly in Moz 1.7.5.

Reproducible: Always

Steps to Reproduce:
1.Open the page in Mozilla 1.8a6 - content is wrongly centered
2.Open the page in IE - it looks as it should
3.Compare with Moz 1.7.5 - it looks as it should

Actual Results:  
Content renders wrong in Moz 1.8a6

Expected Results:  
Centered the table but not its content unless specified; in this example the
content was supposed to be flush left
This might be caused by the Checkin for Bug 273857 from 23.12.2004. 

You can see this too at: http://www.holgermetzger.de/faq.html

But this behaviour seems to be correct. 

The above Site use:
<center>
<table style="border: 2px solid rgb(0, 0, 0);" cellpadding="0"
 cellspacing="0" width="90%">

while <center> is the old equivalent for <div align="center"> and this means
text-align: center and go to the Childs as well. 

center table {text-align: left; } will fix this. 
Using a nonstrict doctype to get quirks rendering will also fix this. 
The site in question is XHTML transitional and, until v1.8, Mozilla has
interpreted the coding not to include the childs. But the behavior exists with
Firefox v1 and, by annecdotal report, with Opera so I suspect that the behavior
is merely showing that Mozilla (and Firefox) are becoming more standards
compliant with each new release.

But my understanding of XHTML transitional is that it is more 'forgiving'. Is
Mozilla (and Firefox) not 'seeing' that?
I'll attach a testcase based on http://keepersoflists.org/mylists.php, which
requires a login.
The text in the testcase is centered in a Firefox nightly from Jan 25, but it is
left-aligned in Internet Explorer (XP SP2), Firefox 1.0, and Mozilla 1.8a4.
Assignee: general → parser
Status: UNCONFIRMED → NEW
Component: General → HTML: Parser
Ever confirmed: true
Keywords: testcase
Product: Mozilla Application Suite → Core
QA Contact: general → mrbkap
Version: unspecified → Trunk
I'm not quite sure where this goes but this isn't a parser bug (the content
model is correct, according to the DOM inspector). Adding qawanted keyword and
moving to Layout.
Assignee: parser → nobody
Component: HTML: Parser → Layout
Keywords: qawanted
QA Contact: mrbkap → layout
See bug 273857 comment 8 and note that Jesse's testcase is in standards mode in
Mozilla and in quirks mode in IE (because IE has a known bug -- any document
with an XML declaration goes into quirks mode).

So this is invalid.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → INVALID
*** Bug 279295 has been marked as a duplicate of this bug. ***
http://opensourcecms.com/index.php?option=content&task=view&id=132 and
http://keepersoflists.org/mylists.php have the XML declaration before the
doctype as described in comment 8, but http://www.holgermetzger.de/faq.html from
comment 1 does not have an XML declaration.
And the website in comment 1 is not centered in a current Mozilla build...
(In reply to comment #11)
> And the website in comment 1 is not centered in a current Mozilla build...

Yes, Holger Metzger has fixed his Site after a hint in d.c.s.mozilla.mailnews at
2005-01-29.
> Yes, Holger Metzger has fixed his Site

And what was the doctype before the "fix"?  Was it one that both Mozilla and IE
render in standards mode? 
(In reply to comment #13)
> And what was the doctype before the "fix"?  

Sorry, I havn't saved his Site before, so I don't know anymore. I have asked
Holger to add an Comment here, hopefully he would. 
*** Bug 280538 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.

Attachment

General

Creator:
Created:
Updated:
Size: