Formatting Numbers and Dates

Subject: Formatting Numbers and Dates
From: Senthil Vaiyapuri <senthil@xxxxxxxxxx>
Date: Fri, 23 Jul 1999 08:25:50 -0700

     Are there builtin ways (methods) available in XSL to format
     numbers and Dates?  With IE5, I could use formatNumber()
     and formatDate() methods (as shown below).  But this
     apparent extenstion (<xsl-eval>) makes the style sheet not

				/* DATE_F - contains a unix time() value */

     <xsl:apply-templates select="DATE_F">
     <xsl:template match="DATE_F">
          <TD align="center">
		<FONT size="2"><xsl:eval>formatDate(new
Date(parseInt(this.text) * 1000).getVarDate(), "MMM dd

				/* NUM_F contains a decimal, with no
trailing zeroes */
    <xsl:apply-templates select="NUM_F">
    <xsl:template match="NUM_F">
          <TD align="center">
		<FONT size="2"><xsl:eval>formatNumber(this.nodeTypedValue,

     Thanks in advance..

Senthil Vaiyapuri
Portal Software

 XSL-List info and archive:

Current Thread