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

How to use multiple xsl:import

Subject: How to use multiple xsl:import
From: Pieter Reint Siegers Kort <pieter.siegers@xxxxxxxxxxx>
Date: Tue, 5 Apr 2005 13:10:51 -0500
multiple xsl
Hi all,

I've got a (collegue's) question on a concept that we're trying out in an
effort to generate a new internal CMS. Basically we're building a static web
page (on a stage server) using modular XSLT, that is, using xsl:import and
xsl:apply-imports.

The question is, in the partial stylesheet below (XSLT 1.0), how to get the
xsl:apply-imports to use 'top.xsl' and subsequently the next xsl:imports to
use 'nav_auto_roll.xsl'.
 
.
. 
<xsl:import href="../includes/top.xsl"/> 
<xsl:import href="../includes/nav_auto_roll.xsl"/>
.
.
.
<td width="760" colspan="2">
	<xsl:apply-imports/>
</td></tr>
<tr>
<td width="125" valign="top">
	<xsl:apply-imports/>
</td>
.
.

It seems that this is not the right approach, as we're dealing with import
precedence, i.e. the result will only show 2 times the last imported
stylesheet (see p.228 of MK's XSLT 2nd Edition) - but there may be some
smart workarounds for this problem? Anyone any ideas? We've tried to name
them but the href attribute is the only one on xsl:import. The processor
seems to forget about 'top.xsl' completely.

I've done a similar but alternative approach myself using ASP or ASP.NET
doing partial XSLT's and building the web page from there. We may be able to
change but want to know first if the above approach would work and what's
best to do.

Cheers and thanx,
<prs/>

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.