Details
-
Bug
-
Status: Resolved
-
Resolution: Fixed
-
2.4Dx
-
None
-
None
-
Operating System: Windows NT/2K
Platform: PC
-
12114
Description
Namespace nodes are not output when using redirection. That is, when the
generated root element is redirected, it receives the correct xmlns declaration.
But when another element is redirected to a new file (becoming that file's root
element), then that element does not get its necessary namespace nodes.
Example:
[source]
<root xmlns="foo"><test/></root>
[xsl]
<xsl:template match="test">
<redirect:write file="newfile.xml">
<xsl:copy/>
</redirect:write>
</xsl:template>
[actual newfile.xml]
<?xml ...>
<test/>
[expected newfile.xml]
<?xml ...>
<test xmlns="foo"/>
I set this bug to Major severity because the resulting file is not XML namespace
compliant and the workaround (see below) is not acceptable by everyone.
Look also in the Xalan-J-user mailing list for a thread with title "redirect
does not output xmlns declaration".