Closed
Bug 24855
Opened 25 years ago
Closed 25 years ago
ADDRESS element inherits style from unclosed P element
Categories
(Core :: Layout, defect, P3)
Tracking
()
VERIFIED
FIXED
People
(Reporter: extremely, Assigned: harishd)
References
()
Details
Attachments
(1 file)
(deleted),
text/html
|
Details |
I'll attach a minimal test case to this to demonstrate. This is goofy in
M12 and build 2000012008. P is closed by all block elements so its style
shouldn't be passed along in HTML4.0
This is works in NS4.70 but it is rarely used so I'm waffling on the severity.
see: http://www.w3.org/TR/html4/struct/text.html#edef-P
and: http://www.w3.org/TR/html4/sgml/dtd.html#block
Interestingly, both NS4 and MOZ treat it as orphan text when the prior
block is open, and thus the line break it rather than paragraph return it.
Hey, I think I got this one...
In the code (lxr search for eHTMLTag_address) in various places you have
ADDRESS the element listed as an INLINE element. In HTML4.0, at least, it is
a BLOCK element. This explains the generic inheritance rules for INLINE being
used in the example attached.
In HTML3.2 ADDRESS was a "Body Text" item but grouped with H1-6 and the other
BLOCK elements as handled in the DTD. In HTML2.0 it was a BLock structure as
well.
This is an out and out bug.
LXR search: http://lxr.mozilla.org/seamonkey/search?string=eHTMLTag_address
As a final point,
http://lxr.mozilla.org/seamonkey/source/htmlparser/src/nsElementTable.cpp
has the ADDRESS element treated properly as a block. There seems to be special
case stuff in this for ADDRESS to contain P or vice-versa which is wrong by all
the DTDs.
Comment 4•25 years ago
|
||
Another great job from extremely@hostile.
The bug is in HTMLParser: reassigned to rickg.
Assignee: pierre → rickg
ADDRESS can be contained in P.
FIXED
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
SPAM. HTML Element component deprecated, changing component to Layout. See bug
88132 for details.
Component: HTML Element → Layout
You need to log in
before you can comment on or make changes to this bug.
Description
•