Re: [xsl] NewBe help!

Subject: Re: [xsl] NewBe help!
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Fri, 3 Aug 2001 15:35:04 +0100
Hi Joe,

> I have just started useing xsl/xml and I haven't puchased a book yet
> how does the syntax work with the document() function when you use
> two variables?

Basically if you pass a relative URI as the value of the first
argument, then you need to resolve that relative URI somehow. If you
don't give a second argument, then the relative URI is resolved
relative to the stylesheet. If you do give a second argument (which
has to be a node), then the relative URI is resolved relative to the
"base URI" of the node, which is usually the same as the URI of the
entity that the node came from.

Typically, you'd use the second argument of the document() function if
the XML document you're processing contains URLs and is in a different
directory from the stylesheet. Then you'd use something like:

  document($URL, .)



Jeni Tennison

 XSL-List info and archive:

Current Thread