XSLTProcessor() in Edge Browser inserts incorrect namespace on transformation RRS feed

  • Question

  • XSLTProcessor in Edge browser inserts xmlns="http://www.w3.org/1999/xhtml" in XML document on elements <form>, <table> and <button> even though default namespace of XML document is not XHTML.


    var processor = new XSLTProcessor()
    var el = processor.transformToDocument(xml);

    Both 'xsl' and 'xml' objects are XML documents loaded via XMLHTTPRequest.responseXML.

    XML passed into transformation:


    XML returned from transformation as 'el':

        <form xmlns="http://www.w3.org/1999/xhtml">
            <group xmlns="">
                <button xmlns="http://www.w3.org/1999/xhtml"></button>


    <?xml version='1.0'?>
    <xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>
    <xsl:output method="xml" omit-xml-declaration="yes"/>

    <xsl:template match="@* | * | comment()" priority="-2">
    <xsl:apply-templates select="@* | * | text() | comment()"/>

    Subsequent transformations on this XML fail as these nodes have an incorrect namespace.

    This transformation logic works correctly in Internet Explorer, and Firefox and Chrome.

    Monday, August 3, 2015 2:18 AM

All replies

  • Hi,

    Thank you for reporting this issue.

    Please also report it in Feedback function in Edge. I will also log this issue and forward to related team. 

    Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Support, contact tnmff@microsoft.com.

    Wednesday, August 5, 2015 8:00 AM