[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Yet Another Grouping Question

Subject: Yet Another Grouping Question
From: Kai.Grossjohann@xxxxxxxxxxxxxxxxxx (Kai Großjohann)
Date: 13 Mar 2000 16:09:12 +0100
tia kai
Input XML fragment:

<list>
    <item><prog>bar</prog><version>2</version></item>
    <item><prog>bar</prog><version>3</version></item>
    <item><prog>foo</prog><version>1.2</version></item>
    <item><prog>foo</prog><version>1.3</version></item>
    <item><prog>xyzzy</prog><version>1.0</version></item>
</list>

Desired output:

HTML table with one row per item, sorted by program name.  All `bar'
lines have green background, all `foo' lines have yellow background,
all `xyzzy' lines have green background, and so on.

I.e.: change background color when prog element changes.

Thanks to the FAQ http://freespace.virgin.net/b.pawson/xsl I think I
know how to create output when the prog element changes, but how to
toggle between green and yellow background?  This would mean I need a
variable which contains the current background color, but since
variable assignment is not possible in XSLT...

tia,
kai
-- 
~/.signature: No such file or directory


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.