function runTests() {
// Test XML document cloning. var d = (new DOMParser()).parseFromString( "http://www.w3.org/1999/xhtml' id='root'>", "text/xml"); var cloneDoc = d.cloneNode(true);
ok(cloneDoc.getElementById("root"), "XML document should have an element with ID 'root'");
ok(cloneDoc.getElementById("child"), "XML document should have an element with ID 'child'");
// Test HTML cloning.
cloneDoc = document.cloneNode(true);
ok(cloneDoc.getElementById("root"), "HTML document should have an element with ID 'root'");
ok(cloneDoc.getElementById("child"), "HTML document should have an element with ID 'child'");
SimpleTest.finish();
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.