using xt-extensions for getting a string of date

Subject: using xt-extensions for getting a string of date
From: felix@xxxxxxxxxxxxxxxxxxxxxx
Date: Tue, 7 Mar 2000 16:51:55 +0100

I am trying to use the extent the date.xsl example from the xt-distro.
I want it to print the string for a given date, not the actual date
like that demo does. I tried something like this


<xsl:template match="/">
    <xsl:if test="function-available('date:to-string') and
      <xsl:variable name="year">2000</xsl:variable>
      <xsl:variable name="month">1</xsl:variable>
      <xsl:variable name="day">2</xsl:variable>
      <p><xsl:value-of select="date:to-string(date:new(2000,1,2))"/></p>
      <p><xsl:value-of select="date:to-string(date:new($year,$month,$day))"/></p>


It should give out the strings for the 02.01.2000. But xt just tells
new:illegal arguments

So I think it is trying to give the arguments as strings instead of
integers as the constructor of Date is expecting. How can I get this
to work? I am especially interested in the second case, where I call
date:new with variables.

Thanks in advance.
 Felix Schumacher

ps: I hope this is not to far off-topic.

 XSL-List info and archive:

Current Thread