Make createDocument call appendChild explicitly for the doctype.
authorMs2ger <ms2ger@gmail.com>
Fri, 03 Jun 2011 09:33:02 +0200
changeset 5301ca6aabc0984
parent 528 6bb5749a1121
child 531 2d23d24dd297
child 561 ad68f8ab9db3
Make createDocument call appendChild explicitly for the doctype.
Overview.html
Overview.src.html
     1.1 --- a/Overview.html	Sat May 28 21:29:55 2011 +0200
     1.2 +++ b/Overview.html	Fri Jun 03 09:33:02 2011 +0200
     1.3 @@ -48,7 +48,7 @@
     1.4  <p><a href="http://www.w3.org/"><img alt="W3C" height="48" src="http://www.w3.org/Icons/w3c_home" width="72"></a></p>
     1.5  <!--end-logo-->
     1.6   <h1>DOM Core</h1>
     1.7 - <h2 class="no-num no-toc" id="editor-s-draft-28-may-2011">Editor's Draft 28 May 2011</h2>
     1.8 + <h2 class="no-num no-toc" id="editor-s-draft-3-june-2011">Editor's Draft 3 June 2011</h2>
     1.9  
    1.10   <dl>
    1.11    <dt>This Version:
    1.12 @@ -91,7 +91,7 @@
    1.13  the <a href="http://www.w3.org/TR/">W3C technical reports index</a> at
    1.14  http://www.w3.org/TR/.</i>
    1.15  
    1.16 -<p>This is the 28 May 2011 Editor's Draft of DOM Core. Please send
    1.17 +<p>This is the 3 June 2011 Editor's Draft of DOM Core. Please send
    1.18  comments to
    1.19  <a href="mailto:www-dom@w3.org?subject=%5BDOMCore%5D%20">www-dom@w3.org</a>
    1.20  (<a href="http://lists.w3.org/Archives/Public/www-dom/">archived</a>)
    1.21 @@ -2417,21 +2417,9 @@
    1.22   arguments <var title="">namespace</var> and <var title="">qualifiedName</var> on
    1.23   <var title="">document</var>. If that threw an exception, terminate these steps.
    1.24  
    1.25 - <li>
    1.26 -  <p>If <var title="">doctype</var> is not null, run the following substeps:
    1.27 -
    1.28 -  <ol>
    1.29 -   <li><p>If the <var title="">doctype</var>'s
    1.30 -   <code title="dom-Node-ownerDocument"><a href="#dom-node-ownerdocument">ownerDocument</a></code> is not null, throw a
    1.31 -   <code title="dom-DOMException-WRONG_DOCUMENT_ERR"><a href="#dom-domexception-wrong_document_err">WRONG_DOCUMENT_ERR</a></code>
    1.32 -   exception and terminate the overall set of steps.
    1.33 -
    1.34 -   <li><p>Set the <var title="">doctype</var>'s
    1.35 -   <code title="dom-Node-ownerDocument"><a href="#dom-node-ownerdocument">ownerDocument</a></code> to
    1.36 -   <var title="">document</var>.
    1.37 -
    1.38 -   <li><p>Append <var title="">doctype</var> to <var title="">document</var>.
    1.39 -  </ol>
    1.40 + <li><p>If <var title="">doctype</var> is not null, call
    1.41 + <var title="">document</var>'s <code title="dom-Node-appendChild"><a href="#dom-node-appendchild">appendChild</a></code>
    1.42 + method with <var title="">doctype</var> as its argument.
    1.43  
    1.44   <li><p>If <var title="">element</var> is not null, append <var title="">element</var>
    1.45   to <var title="">document</var>.
    1.46 @@ -2448,7 +2436,10 @@
    1.47  
    1.48   <li><p>Mark <var title="">doc</var> as being an <a href="#html-document">HTML document</a>.
    1.49  
    1.50 - <li><p>Create a new <code><a href="#documenttype">DocumentType</a></code>, with "<code title="">html</code>" as its <a href="#concept-doctype-name" title="concept-doctype-name">name</a> and with its <code title="dom-Node-ownerDocument"><a href="#dom-node-ownerdocument">ownerDocument</a></code> set to <var title="">doc</var>. Append the newly created node to <var title="">doc</var>.
    1.51 + <li><p>Create a new <code><a href="#documenttype">DocumentType</a></code>, with "<code title="">html</code>"
    1.52 + as its <a href="#concept-doctype-name" title="concept-doctype-name">name</a>. Call
    1.53 + <var title="">doc</var>'s <code title="dom-Node-appendChild"><a href="#dom-node-appendchild">appendChild</a></code>
    1.54 + method with the newly created node as its argument.
    1.55  
    1.56   <li><p>Create an <code title="">html</code> element in the <a href="#html-namespace">HTML
    1.57   namespace</a>, and append it to <var title="">doc</var>.
     2.1 --- a/Overview.src.html	Sat May 28 21:29:55 2011 +0200
     2.2 +++ b/Overview.src.html	Fri Jun 03 09:33:02 2011 +0200
     2.3 @@ -2411,21 +2411,9 @@
     2.4   arguments <var title>namespace</var> and <var title>qualifiedName</var> on
     2.5   <var title>document</var>. If that threw an exception, terminate these steps.
     2.6  
     2.7 - <li>
     2.8 -  <p>If <var title>doctype</var> is not null, run the following substeps:
     2.9 -
    2.10 -  <ol>
    2.11 -   <li><p>If the <var title>doctype</var>'s
    2.12 -   <code title=dom-Node-ownerDocument>ownerDocument</code> is not null, throw a
    2.13 -   <code title=dom-DOMException-WRONG_DOCUMENT_ERR>WRONG_DOCUMENT_ERR</code>
    2.14 -   exception and terminate the overall set of steps.
    2.15 -
    2.16 -   <li><p>Set the <var title>doctype</var>'s
    2.17 -   <code title=dom-Node-ownerDocument>ownerDocument</code> to
    2.18 -   <var title>document</var>.
    2.19 -
    2.20 -   <li><p>Append <var title>doctype</var> to <var title>document</var>.
    2.21 -  </ol>
    2.22 + <li><p>If <var title>doctype</var> is not null, call
    2.23 + <var title>document</var>'s <code title=dom-Node-appendChild>appendChild</code>
    2.24 + method with <var title>doctype</var> as its argument.
    2.25  
    2.26   <li><p>If <var title>element</var> is not null, append <var title>element</var>
    2.27   to <var title>document</var>.
    2.28 @@ -2444,9 +2432,10 @@
    2.29  
    2.30   <li><p>Mark <var title>doc</var> as being an <span>HTML document</span>.
    2.31  
    2.32 - <li><p>Create a new <code>DocumentType</code>, with "<code title>html</code>" as its <span
    2.33 - title=concept-doctype-name>name</span> and with its <code
    2.34 - title=dom-Node-ownerDocument>ownerDocument</code> set to <var title>doc</var>. Append the newly created node to <var title>doc</var>.
    2.35 + <li><p>Create a new <code>DocumentType</code>, with "<code title>html</code>"
    2.36 + as its <span title=concept-doctype-name>name</span>. Call
    2.37 + <var title>doc</var>'s <code title=dom-Node-appendChild>appendChild</code>
    2.38 + method with the newly created node as its argument.
    2.39  
    2.40   <li><p>Create an <code title>html</code> element in the <span>HTML
    2.41   namespace</span>, and append it to <var title>doc</var>.