This is my code:
var doc = document.implementation.createDocument("", "", null);
var msg = document.createElement('message');
doc.appendChild(msg);
xml_serial = (new XMLSerializer).serializeToString(doc);
And I get this output:
<message xmlns="http://www.w3.org/1999/xhtml"> </message>
And my wish is to prevent the namespace, so I want something like this:
<message> </message>
How can I prevent or delete the namespace?