comparing dates help.
I've been looking around for a way to compare dates. And it sounded like xslt can.
I'm trying like this:
<xsl:param name="date" />
<xsl:for-each select="dates/date">
<xsl:variable name="firstDate" select="concat(substring($date, 1,4),substring($date, 6,2),substring($date,9,2))"/>
<xsl:variable name="secondDate" select="concat(substring(., 1,4),substring(., 6,2),substring(.,9,2))"/>
<xsl:if test="$secondDate > $firstDate">
someing
</xsl:if>
</xsl:for-each>
Doesn't seem to be working. Is this the right attempt?
|