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]

RE: Alternating table row colors with recursion



>> I've given up on a similar case where my normal rows,
>> which I can count, have group headers interspersed which mess up the
count.
>> 

>Why would intersperd headers mess up counting?
>You'd just need a select attribute that selects whatever you wanted to
>count, wouldn't you? (eg the count attribute of xsl:number)

I had a stylesheet that output data in groups, with the group header on one
line and the group details on the following lines.  For this it's possible
that there's a count function that tells you how many lines have passed
(e.g. number of details earlier in this group, plus number of headers
earlier, plus total number of details in earlier groups), although I had to
use xsl:sort to get the right sequence, so the preceding axis probably
wouldn't have worked.  But then I had different types of grouped details,
handled by different templates.  And then some of the details required two
lines rather than one.  And then some of the details had addenda with a
varying number of lines...

It's still possible that there's a function to count those lines so the
output HTML could have alternating colours.  It's even possible that I could
have found it, given enough time.  But if I had, I wouldn't have been able
to understand it two months later.


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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]