Re: Using xml:base in an xsl:stylesheet declaration - how about i t?

Subject: Re: Using xml:base in an xsl:stylesheet declaration - how about i t?
From: Dan Morrison <dman@xxxxxxxx>
Date: Wed, 29 Mar 2000 19:49:56 +1200
Kay Michael wrote:
> 
> I think that if you generate the xsl tree by using XSLT, there is no way of
> setting its Base URI.

More to the point, there IS no Base URI. How can this be? 
Are there allowances for a URI to be null? Everything I've seen assumes
that there is some kind of working directory to start from.

In one case I'm generating an XSL programatically, but not using XSL to
do so. But mostly it's for caching. My template just needs to remember
where it came from.

> The Base URI is defined for a result tree fragment,
> but not for the final result tree.

Um, what's the difference here in practice?
In what case would they be different? :-?


--------------------------------------
W3C XSLT

3.2 Base URI
Every node also has an associated URI called its base URI, which is used
for resolving attribute values that represent relative URIs into
absolute URIs. If an element or processing instruction occurs in an
external entity, the base URI of that element or processing instruction
is the URI of the external entity; otherwise, the base URI is the base
URI of the document. The base URI of the document node is the URI of the
document entity. The base URI for a text node, a comment node, an
attribute node or a namespace node is the base URI of the parent of the
node.
--------------------------------------

As far as I can see, this paragraph just doesn't apply to my scenario.
I guess that's because XSL is a file format definition and every file
has a URI. 
... or does it? We've now started regarding XML as abstract data
structures, not bits of a hard drive.

Have I touched on something deep here or am I missing a point somewhere?

.dan.


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


Current Thread