Commit d216309b authored by Michael Kohlhase's avatar Michael Kohlhase

debugging

parent 2a3bc980
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0"
xmlns:omdoc="http://omdoc.org/ns"
xmlns="http://omdoc.org/ns"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
exclude-result-prefixes="omdoc">
<xsl:output method="xml" indent="yes" cdata-section-elements="data"/>
<xsl:template match="*">
<xsl:copy>
<xsl:copy-of select="@*"/>
<xsl:apply-templates/>
</xsl:copy>
</xsl:template>
<xsl:template match="omdoc:imports">
<imports>
<xsl:choose>
<xsl:when test="contains(@from,'..')">
<xsl:copy-of select="@from"/>
</xsl:when>
<xsl:otherwise>
<xsl:attribute name="from">
<xsl:value-of select="concat('#',substring-after(@from,'#'))"/>
</xsl:attribute>
</xsl:otherwise>
</xsl:choose>
<xsl:copy-of select="@*[local-name()!='xref']"/>
<xsl:apply-templates/>
</imports>
</xsl:template>
<xsl:template match="omdoc:ref[@type='include']">
<xsl:message>Processing included Document <xsl:value-of select="@xref"/> ...</xsl:message>
<xsl:apply-templates select="document(@xref)"/>
<xsl:text>&#xA;&#xA;</xsl:text>
</xsl:template>
</xsl:stylesheet>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment