You are not logged in.
This stylesheet take a monetary value in an element named "price" and separates the Rand and Cents values into individual elements
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="/">
<xsl:variable name="s" select="//*[local-name()='price']" />
<cents><xsl:value-of select="substring($s, string-length($s) - 1,2)" /></cents>
<Rands><xsl:value-of select="substring($s, 1, string-length($s) - 2)" /></Rands>
</xsl:template>
</xsl:stylesheet>
Offline