Closed
Bug 12998
Opened 25 years ago
Closed 25 years ago
body has extra text node (whitespace) at beginning
Categories
(Core :: DOM: Core & HTML, defect, P3)
Tracking
()
VERIFIED
FIXED
M15
People
(Reporter: dbaron, Assigned: rickg)
Details
(Whiteboard: [TESTCASE])
Attachments
(2 files)
DESCRIPTION: You seem to be putting any whitespace that occurs before the
beginning of the body element into the beginning of the body element. This
causes body.firstChild to incorrectly be an [object Text] when the body start
tag is immediately followed by a start tag for another element.
STEPS TO REPRODUCE: Load attached test case (possibly twice due to some script
bugs these days). Look in the text window for output from dump().
ACTUAL RESULTS: [object Text]
EXPECTED RESULTS: [object HTMLParagraphElement]
DOES NOT WORK CORRECTLY ON:
* Linux, viewer, 1999-08-30-01-M10
ADDITIONAL INFORMATION:
I will attach a second test case with no whitespace before the beginning of the
body element that does give the desired results, and shows that whitespace
before the beginning of body is the culprit.
I don't know how hard this is to fix while maintaining backward compatibility,
but in theory you should handle correct documents correctly.
Reporter | ||
Comment 1•25 years ago
|
||
Reporter | ||
Updated•25 years ago
|
Whiteboard: [TESTCASE]
Reporter | ||
Comment 2•25 years ago
|
||
Moving all non-DOM[012], non-crash bugs to M15.
Reporter | ||
Comment 5•25 years ago
|
||
I will check (sometime) to see if this is fixed, and, if it is, mark it a
duplicate of bug 13688.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
This appears to have been fixed by earlier improvements to the parsing engine
that deal with how ws/nl sequences before the body are treated.
Updated•24 years ago
|
Component: DOM Level 1 → DOM Core
Component: DOM: Core → DOM: Core & HTML
QA Contact: stummala → general
You need to log in
before you can comment on or make changes to this bug.
Description
•