|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] <xsl:choose> or variable syntax incorrect?
Same problem...but perhaps not the variable name issue? I've used the current() syntax per Dimitri. Again, I'm trying to get a navy row if the when test < 1 count, otherwise red. My xml source has three <Station> elements, 2 have <Board> elements, 1 does not. However, all rows remain navy. Any other comments on where I could be gong astray with the following? Thanks again. Kathy <xsl:template match="Station"> <xsl:variable name="boards" select="//Station[current()/@name]/Boards/Board" /> <xsl:variable name="nboards" select="count($boards)" /> <xsl:choose> <xsl:when test="$nboards < 1"> <tr bgcolor="navy" valign="middle"> <td><xsl:value-of select="@name"/></td> </xsl:when> <xsl:otherwise> <tr bgcolor="red" valign="middle"> <td><xsl:value-of select="@name"/></td> </xsl:otherwise> </xsl:choose> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








