|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
|
xmlns:xs="http://www.w3.org/2001/XMLSchema"
|
|
exclude-result-prefixes="xs" version="2.0">
|
|
<xsl:output indent="yes"/>
|
|
|
|
<xsl:template name="start" match="/">
|
|
<table>
|
|
<xsl:call-template name="createlines">
|
|
<xsl:with-param name="i" select="1"/>
|
|
<xsl:with-param name="rcount" select="8"/>
|
|
<xsl:with-param name="ccount" select="5"/>
|
|
</xsl:call-template>
|
|
</table>
|
|
</xsl:template>
|
|
|
|
<xsl:template name="createlines">
|
|
<xsl:param name="i"/>
|
|
<xsl:param name="rcount"/>
|
|
<xsl:param name="ccount"/>
|
|
<xsl:if test="$i <= $rcount">
|
|
<tr>
|
|
<xsl:call-template name="createcols">
|
|
<xsl:with-param name="i" select="1"/>
|
|
<xsl:with-param name="ccount" select="$ccount"/>
|
|
</xsl:call-template>
|
|
</tr>
|
|
<xsl:call-template name="createlines">
|
|
<xsl:with-param name="i">
|
|
<xsl:value-of select="$i + 1"/>
|
|
</xsl:with-param>
|
|
<xsl:with-param name="rcount">
|
|
<xsl:value-of select="$rcount"/>
|
|
</xsl:with-param>
|
|
<xsl:with-param name="ccount" select="$ccount"/>
|
|
</xsl:call-template>
|
|
</xsl:if>
|
|
</xsl:template>
|
|
|
|
<xsl:template name="createcols">
|
|
<xsl:param name="i"/>
|
|
<xsl:param name="ccount"/>
|
|
<xsl:if test="$i <= $ccount">
|
|
<td/>
|
|
<xsl:call-template name="createcols">
|
|
<xsl:with-param name="i">
|
|
<xsl:value-of select="$i + 1"/>
|
|
</xsl:with-param>
|
|
<xsl:with-param name="ccount" select="$ccount"/>
|
|
</xsl:call-template>
|
|
</xsl:if>
|
|
</xsl:template>
|
|
|
|
</xsl:stylesheet>
|