Re: base-uri

>>Date: Mon, 14 Jan 2002 13:27:47 GMT
>>Message-Id: <200201141327.NAA04435@penguin.nag.co.uk>
>>From: David Carlisle <davidc@nag.co.uk>
>>To: www-xml-query-comments@w3.org, xsl-editors@w3.org
>>Subject: base-uri


>>According to XSLT 1, every node had a base URI, and in particular could
be used as the second argument to document() to provide the base against
which relative URI references are resolved.

>>XSLT 2's description of document() refers to the data model for the
base-uri of the node supplied in the second argument.

>>The data model specifies that the base uri for certain node types
(comment attributes, namespaces, text) is ().

I propose to fix this in the definition of the XSLT 2.0 document() function
by saying that where the node in question has no base URI, we will use the
base URI of its containing element. Parentless text and attribute nodes
can't at present be referenced in XSLT, but we can make it an error to try
to resolve a relative URI against such a node.

We have an outstanding issue against the document() function currently
defined in Functions & Operators, which needs to be rewritten to absorb much
of the semantics of the XSLT function, in particular the rules for resolving
relative URIs.

Mike Kay

Received on Tuesday, 29 January 2002 07:55:22 UTC