I need to add an XML to my stylesheet.
Here is the problem
I have an XSL as follows:
Code:
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:fix="http://www.fixprotocol.org/FIXML-4-4"
xmlns:i="http://www.abc.com/interests:i"
exclude-result-prefixes="">
<xsl:output method="xml"/>
<xsl:param name="Description">EQ.D</xsl:param>
<xsl:template match="fix:FIXML">
<xsl:apply-templates select="fix:Order"/>
</xsl:template>
<xsl:template match="fix:Order">
<xsl:element name="i:Interest">
<xsl:element name="strategies.Settlement">
<xsl:value-of select="@SettlDt"></xsl:value-of>
<xsl:element name="Delta"></xsl:element>
<xsl:element name="Ref"></xsl:element>
</xsl:element>
2) I have an XML document which is:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<i:Underlying value="KGF" xmlns:common="http://www.ABC.com/common" xmlns:i="common">
<common:Code>KGF</common:Code>
<common:Reuters>KGF.L</common:Reuters>
</i:Underlying>
3) The entire XML should look like this:
Code:
<Interest>
<strategies.Settlement>0</strategies.Settlement>
<Delta/>
<Ref/>
<i:Underlying value="KGF">
<common:Code>KGF</common:Code>
<common:Reuters>KGF.L</common:Reuters>
</i:Underlying>
</Interest>
How can I include the XML contents in my XSL? Can anybody please suggest?
Is this possible?