Closed Bug 162441 Opened 22 years ago Closed 22 years ago

Content Model for this testcase isnot correct

Categories

(Core :: DOM: HTML Parser, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: jerry.tan, Assigned: harishd)

Details

Testcase: <p/>abc

when access using DOM inspector, it seems like '<p>abc'.
I think mozilla should treat it as '<p></p>abc'
I think it is a parser's bug.
Fix on htmlparser can fix this bug.

so set component as parser.
Is this in HTML or in XML?
Testcase is html
You may want to post the testcase in such cases, you know.... ;)

For HTML, we should not be closing out the <p> when we see <p/>.  We used to do
this, and it breaks many sites.  If a non-XHTML document is doing this, there is
absolutely no reason to parse it per the XML rules (and in fact, we could make a
case for parsing per the SGML rules then, so <p/> would be the same as <p>&gt;).
 If it's XHTML1, it being served as text/html is a violation of the XHTML1
specification, which says that only XHTML1 documents that follow Appendix C of
the specification should be served as text/html.  See section C.3 of Appendix C,
which covers this case.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.