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

Re: counting preceding siblings in with-param

Subject: Re: counting preceding siblings in with-param
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Wed, 23 Jul 2003 11:02:29 -0400
Re:  counting preceding siblings in with-param
Hi John,

At 10:38 AM 7/23/2003, you wrote:
I need to move the template into its own file (to make it reusable)

Sounds good....


 and
so I need to pass in the section-number as a parameter, instead of
calculating it inside the template:

Why does this follow? Can't you generate the number in the template anyhow?


The fact that the two templates start life in different files has no impact on their functionality (pace differences in template precedence due to xsl:import) -- the same techniques for generating numbers will work in any case, once the stylesheet is compiled and run.

Maybe there's a reason you haven't given as to why you have to pass it as a parameter?

BTW, you might consider using <xsl:number/> as a more robust way of generating numbers, if you haven't already. It's not always better, and it doesn't do what you're asking for, but it does have some nice features.

Cheers,
Wendell

___&&__&_&___&_&__&&&__&_&__&__&&____&&_&___&__&_&&_____&__&__&&_____&_&&_
    "Thus I make my own use of the telegraph, without consulting
     the directors, like the sparrows, which I perceive use it
     extensively for a perch." -- Thoreau


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.