This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: Document() function
- To: xsl-list at lists dot mulberrytech dot com
- Subject: Re: [xsl] Document() function
- From: Mike Brown <mike at skew dot org>
- Date: Thu, 15 Mar 2001 13:55:39 -0700 (MST)
- Reply-To: xsl-list at lists dot mulberrytech dot com
Borca, Olivier wrote:
> I am looking for help about the 'document()' function but I didnt
> manage to find something good.
> Can anyone help me with that ?
If you call document() with one argument, the argument is coerced to a
string and is assumed to be a URI that identifies an XML document. That
document is parsed and its root node is returned by the
function. You might use it like this:
<xsl:value-of select="document('foo.xml')/path/to/some/nodes"/>
or
<xsl:variable name="foo" select="/path/to/element/containing/URI/text()"/>
<xsl:value-of select="document($foo)/path/to/some/nodes"/>
You can use multiple arguments, but to learn about that, you should just
wait for Mike Kay's book to arrive in your mailbox!
- Mike
____________________________________________________________________
Mike J. Brown, software engineer at My XML/XSL resources:
webb.net in Denver, Colorado, USA http://skew.org/xml/
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list