This is the mail archive of the xsl-list@mulberrytech.com mailing list .
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Hi! I'm using Xeena 1.1 to create HTML files from XML files. I'm dealing with a list of <option> elements which should be displayed in a table, each row one element. To make it a little more readable, I would have to have an index (formatted as a), b), c) ...) for each row. To obtain the current index I count the preceding-sibling::option axis. This all works pretty well, just when I want to convert the numerical index into the corresponding letter, the XSL engine can't parse the stylesheet anymore. The code I'm using looks like this: <xsl:template match="option" mode="HTML"> <xsl:variable name="rowIndex"><xsl:value-of select="count(preceding-sibling::option)"/></xs:variable> <TR> <TD> <xsl:number value="number($rowIndex+1)" format="a"/> </TD> <TD> further row content </TD> </TR> </xsl:template> The error message is pretty meaningless: XSL Error: SAX Exception, Location file: option.xsl, line 15, offset 62 (which is actually the closing angle bracket of the <xsl:number/> tag) If I replace the <xsl:number value="number($rowIndex+1)" format="a"/> tag with <xsl:value-of select="number($rowIndex+1)"/> I get the index I want, just as number and not as a letter. Since I already use numbers for a different level of nested list, this would cause confusion and I don't want to get into hierarchical numbering, because this would make the column pretty wide (besides I would also want to do that with <xsl:number> and not manually). What do I do wrong? Or doesn't the XSLT engine in built-in Xeena support <xsl:number>? I thought that was a mandatory element... Any ideas? Thanx in advance, Ragnar
S/MIME Cryptographic Signature
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |