View Single Post
  #1 (permalink)  
Old December 3rd, 2019, 01:28 PM
Neal Neal is offline
Friend of Wrox
Points: 718, Level: 10
Points: 718, Level: 10 Points: 718, Level: 10 Points: 718, Level: 10
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2006
Location: Ennis, Clare, Ireland.
Posts: 131
Thanks: 10
Thanked 0 Times in 0 Posts
Default Adding multiple namespaces to root element

Hi,

version 1.0

I have a requirement to output a root element that contains 2 namespaces. Neither of the namespaces are contained within the input xml. The desired output is :

Code:
<Document xmlns="example:01test:02" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Level1>
.... 
</Level1>
</Document>
How do I achieve this ?

If I select
Code:
 
<xsl:template match="/">
<Document xmlns="example:01test:02" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

<Level1>
.... 
</Level1>
</Document>
</xsl:template>
Then just the following is output :
Code:
<Document xmlns="urn:iso:std:iso:20022:tech:xsd:pain.001.001.03">
Thanks in advance
__________________
Neal

A Northern Soul
Reply With Quote