Please specify that when the MIME type argument to parseFromString is "text/html", the other argument gets parsed as HTML in the non-fragment mode with scripting disabled (<script> elements get marked unexecutable and the contents of <noscript> get parsed as markup). Regardless of <meta>s, the resulting document reports UTF-8 as its encoding. What the compatMode property of the resulting document reports depends on doctype as usual.
This is implemented in Firefox 12 and up.
Thanks. Let me know if I need anything else.
Looks good. Thanks.