summaryrefslogtreecommitdiff
path: root/examples/xsl/sum1.xsl
diff options
context:
space:
mode:
Diffstat (limited to 'examples/xsl/sum1.xsl')
-rw-r--r--examples/xsl/sum1.xsl12
1 files changed, 12 insertions, 0 deletions
diff --git a/examples/xsl/sum1.xsl b/examples/xsl/sum1.xsl
new file mode 100644
index 0000000..a595171
--- /dev/null
+++ b/examples/xsl/sum1.xsl
@@ -0,0 +1,12 @@
+<?xml version="1.0"?>
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+<xsl:output method="text"/>
+<xsl:param name="inputFile">-</xsl:param>
+<xsl:template match="/">
+ <xsl:call-template name="t1"/>
+</xsl:template>
+<xsl:template name="t1">
+ <xsl:value-of select="sum(/xml/table/rec/numField)"/>
+ <xsl:value-of select="'&#10;'"/>
+</xsl:template>
+</xsl:stylesheet>