[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: mode
At 2011-04-14 20:40 +0100, Andrew Welch wrote:
> Remember that mode names can be namespace qualified. When I create XSLT I use the same two-namespace convention for all globally-declared variables in the library. And keys. And named templates. *Everything* with a globally-scoped name in the library is namespace qualified. I don't bother with locally-scoped variables. Without namespaces, if my imported library makes use of a global variable named "x", and my user's importing stylesheet inadvertently declares its own variable named "x", then my library won't work as expected. Namespaces in libraries avoid execution errors and duplicate declaration errors. Very useful. And this approach has been available since day one of XSLT 1.0 and so has been a long-time practice for me. I first started using it when contracted to create a library being sent out of the development team to many remote departments who were going to have their own developers write importing stylesheets. . . . . . . . . . . Ken -- Contact us for world-wide XML consulting & instructor-led training Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/ G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx Legal business disclaimers: http://www.CraneSoftwrights.com/legal
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|