How to change the content of an element with childNodes (Javascript)?
<p>How can I change the content of an element with childNodes (Javascript)?
I tried something but it did not work.</p>

<pre><code>&lt;!DOCTYPE html&gt;
&lt;html&gt;
    &lt;head&gt;
        &lt;meta charset="utf-8"&gt;
        &lt;title&gt;Zitat&lt;/title&gt;
        &lt;script type="text/javascript"&gt;
            var htmlNode = document.documentElement;
            var emNode = htmlNode.childNodes[1].childNodes[0].childNodes[1].childNodes[1];
            emNode.innerHtml = "BBB";
        &lt;/script&gt;
    &lt;/head&gt;
    &lt;body&gt;
        &lt;ul&gt;
            &lt;li&gt;Hello World&lt;/li&gt;
            &lt;li&gt;AAA &lt;em&gt;DDD&lt;/em&gt; CCC.&lt;/li&gt;
        &lt;/ul&gt;
    &lt;/body&gt;
&lt;/html&gt;
</code></pre>