[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: XSL Counters list order?
Subject: Re: XSL Counters list order? From: James Clark <jjc@xxxxxxxxxx> Date: Mon, 04 Jan 1999 09:26:04 +0700 |
Tyler Baker wrote: > > In the latest XSL spec: > > "Counter values are inserted using xsl:counter and xsl:counters > elements. The name of the counter is specified with the name attribute. > xsl:counter first constructs a list of length one containing the value > of the named counter from the nearest ancestor in the result tree that > has a counter with the specified name; xsl:counters first constructs a > list containing, for each ancestor in the result tree that has a counter > with the specified name, the value of named counter from that ancestor. > xsl:counter and xsl:counters then convert the list of numbers into a > string using the attributes specified in Section 2.7.10.3: Number to > String Conversion Attributes; when used with xsl:counter and > xsl:counters the value of each of these attributes is interpreted as an > attribute value template." > > Now what to do about xsl:counter is pretty clear. Just format the > number of the first ancestor in the result tree. However, the order > that the list of ancestors for xsl:counters is not clear to me. Should > the order be from first ancestor found to last ancestor found or the > other way around. My assumption is that the list should be first > ancestor found, second ancestor found, etc. The order in the list is document order (ie a parent would precede its child). It has to be this way for xsl:counters to be useful (you want to be able to get numbering like 2.3.7 with nested div elements). James XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
XSL Counters list order?, Tyler Baker | Thread | [no subject], Flow Simulation |
Re: XT extension mechanism, James Clark | Date | xsl:counter-scope, Paul Spencer |
Month |
Keywords