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

RE: importing/including a stylesheet with a dynamic na

Subject: RE: importing/including a stylesheet with a dynamic name (can't)
From: Adam Van Den Hoven <Adam.Hoven@xxxxxxxxxxxx>
Date: Tue, 30 Jan 2001 18:52:15 -0800
including a stylesheet html
> The desire for run-time xsl:import is voiced quite often, and 
> for once it's
> nice to hear exactly why you want it, so that I can tell you 
> why you don't!
> Instead of A conditionally importing stylesheet B1, B2, or B3 
> each of which
> replaces part of A, the user should select stylesheet B1, B2, 
> or B3, each of
> which imports the fixed stylesheet A and replaces or 
> overrides parts of it.
> The special-case stylesheet should import the general-case 
> stylesheet, not
> the other way around.

While I agree with these facts (they had never occured to me, so thank you)
I have a case where a conditional import is necessary. I have an application
where I need to separate layout from style. Typically I'd use CSS to handle
style, except for a few things. First, not all my targets are CSS compliant
(AvantGo for instance is a light version of HTML3.2 or something). Second my
styles include a lot of information that isn't CSS, or require CSS 2 which
most commercial browsers (IE) don't support. Typically we use our style docs
(which we call skins) for branding details like logos and the like. Because
my skins are destination agnostic and my layouts are branding agnostic, I
need to be able to transform foo.xml using layoutx.xsl and skinz.xsl.

Currently we use quasi XSL documents for the layout and the skin, pass them
through compiling XSL to create the actual transform that we would apply.
Since running transforms on the fly is costly compared to storing every
possible combination of layout and skin, we compile all our transform ahead
of time. I've thought about allowing the layout to specify which skins could
be valid (that is load them all) and then use parameters to selectively call
particular skins. This gets rather gruesome if I have a template that could
concievable use all skins.


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

Current Thread


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.
First Name
Last Name
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.