Ken Theng wrote:
How do you do the above steps. I tried DOMParser but it does not support "text/html" only support "text/xml" and xhtml. thanks ..hope u reply soon

Why don't you use XHTML then?

Creating an element:

var elm = Editor.document.createElement("div");
elm.innerHTML = "foo <span>bar</span>";
alert(elm.childNodes[0].nodeValue); // should be "foo"
alert(elm.childNodes[1].nodeName); // should be "span"
alert(elm.childNodes[1].firstChild.nodeValue); // should be "bar"

Daniel
_______________________________________________
mozilla-embedding mailing list
mozilla-embedding@mozilla.org
http://mail.mozilla.org/listinfo/mozilla-embedding

Reply via email to