Subject: Re: [xsl] newbie prob - Template and navigation confusion??? From: David Carlisle <davidc@xxxxxxxxx> Date: Thu, 3 Feb 2005 13:53:46 GMT |
<xsl:when test="TEAM/TEAM_ROW/NAME/NAME_ROW/SALARY>'30000'"> This is true if _any_ SALARY is greater than 30000 (incidentally you want 30000 not '30000', it comes to the same thing but just saves the processor converting between strings and numbers) But if that is true you do: <xsl:apply-templates select="TEAM/TEAM_ROW/NAME/NAME_ROW" ie apply templates to all the rows, I think you want to get rid of your cxsl:choose and ypur light and dark moses and just have <xsl:apply-templates select="TEAM/TEAM_ROW/NAME/NAME_ROW" <xsl:template match="NAME_ROW"> <tr> <td><xsl:value-of select="LAST_NAME"/></td><td> <xsl:if test="SALARY > 30000"> <xsl:attribute name="bgcolor">gray</xsl:attribute> </xsl:if> <xsl:value-of select="SALARY"/></td> </tr> </xsl:template> David ________________________________________________________________________ This e-mail has been scanned for all viruses by Star. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk ________________________________________________________________________
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] newbie prob - Template and na, Nick Roberts | Thread | RE: [xsl] newbie prob - Template an, Michael Kay |
[xsl] newbie prob - Template and na, Nick Roberts | Date | RE: [xsl] String formatting, Bhaskar, Rajan |
Month |