W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2009

[whatwg] DOMParser / XMLSerializer

From: Jonas Sicking <jonas@sicking.cc>
Date: Wed, 20 May 2009 16:46:24 -0700
Message-ID: <63df84f0905201646u7820d55dvfce7401f8c7ab594@mail.gmail.com>
On Wed, May 20, 2009 at 2:20 PM, Anne van Kesteren <annevk at opera.com> wrote:
> Although it seems most browsers have adopted these APIs, HTML5 offers basically identical APIs in the form of
>
> ?document.innerHTML
>
> or is there something that DOMParser / XMLSerializer can do that document.innerHTML cannot?

Mostly I think these APIs came about before innerHTML was supported in
XML content. DOMParser is also somewhat more convenient if you want a
full document back. And XMLSerializer is more convenient if you want
an XML serialization of text/html content.

/ Jonas
Received on Wednesday, 20 May 2009 16:46:24 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:08:49 UTC