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

RE: XSL:Number, value attribute

Subject: RE: XSL:Number, value attribute
From: "Chris Bowditch" <bowditch_chris@xxxxxxxxxxx>
Date: Fri, 27 Jun 2003 09:01:17 +0000
number value
Hi Michael,

thanks for this swift response. Your answer explains a lot. The two "modes" of using xsl:number were not made clear in the books and websites I have consulted on this issue. They lead to believe value allows the default of position() to be overridden.

I was hoping to use xsl:number to process xml like;

<list seed="3" format="1.a">
<item>item 1</item>
<item>item 2
<list seed="2">
<item>sub item 1</item>
<item>sub item 2</item>
</list>
</item>
<item>item 3</item>
</list>

to get;

3. item 1
4. item 2
 4.b. sub item 1
 4.c. sub item 2
5. item 3

currently I use xsl:number for this without seed

Thanks once again for your answer

Chris

From: "Michael Kay" <mhk@xxxxxxxxx>

Using the "value" attribute of xsl:number gives you access to the number
formatting functionality of xsl:number without the node-counting
functionality. For example

<xsl:number value="7" format="i"/>

gives you "vii", regardless of where the context node is in the source
tree. This means that value can't be used with multi-level numbering (at
least in XSLT 1.0 - in 2.0 the value attribute can be a sequence of
numbers).


<snip/>


_________________________________________________________________
Stay in touch with absent friends - get MSN Messenger http://www.msn.co.uk/messenger



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.