I adapted your above example to create:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="
<xsl:template match="/">
<html>
<head>
<title>Merging of multiple xml Documents using XSLT</title>
</head>
<!--===============Files are stored as variables=====================-->
<!--<xsl:for-each select="/DOCUMENTS/DOCUMENT">-->
<xsl:variable name="Doc" select="document('CSS_Acceleration ACU Control - Acceleration ACU Control().xml')"/>
<xsl:apply-templates select="$Doc/* "/>
<!--</xsl:for-each>-->
<body/>
</html>
</xsl:template>
<xsl:template match="OBJECT[TYPE = 'Heading']">
<H2><A><xsl:attribute name="name"><xsl:value-of select="HEADING"/><xsl:value-of select="ID"/></xsl:attribute><xsl:value-of select="HEADING"/></A></H2>
<P><xsl:value-of select="TEXT"/></P>
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="OBJECT[TYPE = 'Requirement']">
<A name="A link Value"><H3>Requirement: <xsl:value-of select="ID"/></H3></A>
<H3><A><xsl:attribute name="name"><xsl:value-of select="HEADING"/><xsl:value-of select="ID"/></xsl:attribute>Requirement: <xsl:value-of select="ID"/></A></H3>
<P>Text:<xsl:value-of select="TEXT"/></P>
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="OBJECT[TYPE = 'Informative Text']">
<P>Text</P>
<I><xsl:value-of select="TEXT"/></I>
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="LINKS">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="OUTGOING_LINKS[LINK]">
<P>Outgoing Links</P>
<xsl:for-each select="LINK">
<LI><xsl:value-of select="MODULE"/> - <xsl:value-of select="HEADING"/>(<xsl:value-of select="ID"/>) Type: <xsl:value-of select="TYPE"/></LI>
</xsl:for-each>
</xsl:template>
<xsl:template match="INCOMING_LINKS[LINK]">
<P>Incoming Links</P>
<xsl:for-each select="LINK">
<LI><xsl:value-of select="MODULE"/> - <xsl:value-of select="HEADING"/>(<xsl:value-of select="ID"/>) Type: <xsl:value-of select="TYPE"/></LI>
</xsl:for-each>
</xsl:template>
<xsl:template match="SUB_HEADING">
<H3><A><xsl:attribute name="href"><xsl:value-of select="MODULE"/> - <xsl:value-of select="HEADING"/>(<xsl:value-of select="ID"/>).xml</xsl:attribute><xsl:value-of select="HEADING"/></A></H3>
<!--===============<xsl:element name="A" use-attribute-sets="LinkSet"/>-->
</xsl:template>
</xsl:stylesheet>
Which produced:
;
Requirement:
Requirement:
Text:
Text
Outgoing Links
· - () Type:
Incoming Links
· - () Type:
- ().xml
in internet explorer.
Can you tell me what I’ve done wrong. Ideally the for loop I’ve commented out would loop through a list of document names in the file which calls the style sheet.