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

Re: unsuspected output

Subject: Re: unsuspected output
From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx>
Date: Mon, 01 Mar 2004 08:56:36 -0500
Re:  unsuspected output
At 2004-03-01 14:31 +0100, Nikolas Nehmer wrote:
<xsl:apply-templates select="document($file)/*" mode="minimal_list">
        <xsl:with-param name="file" select="$file"/>
</xsl:apply-templates>
...
This XSL should not produce any output except the Heading because the
template which is applied by the apply-templates element is not present
(not included jet). But it produces output, namely the content of
document($file)/* (the select statement in apply-templates). Why?

I'm guessing the built-in template rules are giving you your grief. If you do not supply a template rule for a node that is pushed at your stylesheet, then the built-in template rules are engaged and their behaviour is to continue processing the tree in a hiearchical fashion.


Any suggestions?

Instead of pushing the document element of your remote file, only push the node in the remote file that you want processed.


I hope this helps.

......................... Ken

--
US XSL training: Washington,DC March 15; San Francisco,CA March 22
World-wide on-site corporate, government & user group XML training
G. Ken Holman                 mailto:gkholman@xxxxxxxxxxxxxxxxxxxx
Crane Softwrights Ltd.          http://www.CraneSoftwrights.com/s/
Box 266, Kars, Ontario CANADA K0A-2E0    +1(613)489-0999 (F:-0995)
Male Breast Cancer Awareness  http://www.CraneSoftwrights.com/s/bc


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.