Subject: RE: [xsl] Rounding a number From: cknell@xxxxxxxxxx Date: Fri, 15 Sep 2006 12:50:09 -0400 |
<xsl:value-of select="round(1000*(4 div 3)) div 1000"/> -- Charles Knell cknell@xxxxxxxxxx - email -----Original Message----- From: Sam Carleton <scarleton@xxxxxxxxxxxxxxxx> Sent: Fri, 15 Sep 2006 12:43:02 -0400 To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: [xsl] Rounding a number Within the XSLT, I am doing some division, such as <xsl:value-of select="4 div 3"/> Of course the problem is that I get "1.3333333333333332" I need to round that down to three decimals. What is the best approach in XSLT 1.0? Sam -- Miltonstreet Photography http://www.miltonstreet.com
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Rounding a number, Michael Kay | Thread | [xsl] Conditional Merging of the n, Senthilkumaravelan K |
[xsl] Rounding a number, Sam Carleton | Date | RE: [xsl] Rounding a number, Michael Kay |
Month |