Closed
Bug 117339
Opened 24 years ago
Closed 23 years ago
documentation on insertBefore is wrong
Categories
(Documentation Graveyard :: Web Developer, defect)
Documentation Graveyard
Web Developer
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: sicking, Assigned: oeschger)
References
()
Details
The documentation for insertBefore is compleatly wrong, see
http://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-952280727
Comment 1•24 years ago
|
||
It should read:
*****************************************
The insertBefore method allows you to insert a node before a reference element
as a child of the current node.
Syntax:
insertedElement = element.insertBefore(newElement, referenceElement);
Parameters:
insertedElement: The node being inserted
newElement: The node to insert
referenceElement: "newElement" will be inserted before "referenceElement"
Example:
parentDiv = document.getElementById("parentDiv");
sp2 = document.getElementById("childSpan");
sp1 = document.createElement("span");
parentDiv.insertBefore(sp1, sp2);
BTW, there's a problem at the http://mozilla.org/docs/dom/domref/ page.
The "DOM Window Reference" is not a top-level title. Must be a markup error.
Thanks Sicking btw :)
| Assignee | ||
Comment 2•23 years ago
|
||
Accepting. Fixed in next rev of domref. Thanks sicking and fabian
Status: NEW → ASSIGNED
| Assignee | ||
Comment 3•23 years ago
|
||
marking FIXED.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•