Subject: RE: [xsl] Variable select="concat()" not loading variable. From: Sundar Shanmugasundaram <SSHANMUGASUNDARAM@xxxxxxxxxxxxx> Date: Thu, 24 Apr 2003 14:08:58 +0530 |
You could do like this: <xsl:variable name="timestamp"> <xsl:for-each select="ROW/TIMESTAMP"> <xsl:value-of select="."/> <xsl:if test="position() != last()"> <xsl:value-of select="$delim"/> </xsl:if> </xsl:for-each> </xsl:variable> sundar -----Original Message----- From: Simon Kelly [mailto:kelly@xxxxxxxxxx] Sent: Thursday, April 24, 2003 1:51 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: [xsl] Variable select="concat()" not loading variable. Hi all, I am trying to concatinate a collection of text() strings (see xsl below) however the variable (timestamps) is not being filled with any data. Could someone tell me why? The total number of timestamps to be concatinated is 10,000. Kind regards Simon [code] <!-- <xsl:for-each select="ROW/TIMESTAMP"> <xsl:if test="position() = 1"> <xsl:element name="starttime"><xsl:value-of select="." /></xsl:element> </xsl:if> <xsl:if test="position() = last()"> <xsl:element name="endtime"><xsl:value-of select="." /></xsl:element> </xsl:if> <xsl:variable name="timestamps" select="concat($timestamps, ./text())" /> <xsl:if test="position() != last()"> <xsl:variable name="timestamps" select="concat($timestamps, $delim)" /> </xsl:if> </xsl:for-each> --> "Make it idiot proof, and someone will make a better idiot" - Anon Institut fuer Prozessdatenverarbeitung und Elektronik, Forschungszentrum Karlsruhe GmbH, Postfach 3640, D-76021 Karlsruhe, Germany. Tel: (+49)/7247 82-4042 E-mail : kelly@xxxxxxxxxx XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Variable select="concat(), Michael Kay | Thread | RE: [xsl] Variable select="concat(), Jarno . Elovirta |
[xsl] Variable select="concat()" no, Simon Kelly | Date | RE: [xsl] Variable select="concat(), Jarno . Elovirta |
Month |