|
Subject: Re: [xsl] Re: Keeping a running total? From: "andrew welch" <andrew.j.welch@xxxxxxxxx> Date: Tue, 11 Jul 2006 16:55:14 +0100 |
<xsl:for-each select="document('factories.xml')//factory">
<xsl:choose>
<xsl:when test="count(preceding-sibling::factory/@widget) > $limit">
<!-- output gadgets -->
<tr>
<td><xsl:value-of select="@name" /></td>
<td>nbsp</td>
<td><xsl:value-of select="$gadgets" /></td>
</tr>
</xsl:when>
<xsl:otherwise>
<!-- output widgets -->
<tr>
<td><xsl:value-of select="@name" /></td>
<td><xsl:value-of select="@widgets" /></td>
<td>nbsp</td>
</tr>
</xsl:otherwise>
</xsl:choose>Failing that, come up with a concise input XML and give an example of the required output XML. Your original question was a bit wordy...
Any other takers?
I'd have to have to resort to some hack if I can do this with XSL.
-S
On 7/10/06, Steve <subsume@xxxxxxxxx> wrote: > Problem: I need to make a table of the output required of 4 factories > next month. > > Widgets Gadgets > Factory A 2 > Factory B 3 > Factory C 4 > Factory D 1 > > Widget quota = 5 > Gadget quota = 5
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] Re: Keeping a running tot, Steve | Thread | Re: [xsl] Re: Keeping a running tot, Steve |
| Re: [xsl] Re: Keeping a running tot, Dimitre Novatchev | Date | Re: [xsl] Procesing XHTML files wit, Mukul Gandhi |
| Month |