Re: xml-stylesheet base resource identifier

* Henry S. Thompson wrote:
>I think the document itself answers that question, by saying
>
> "The semantics of the pseudo-attributes are exactly as with <LINK
>  REL="stylesheet"> in HTML 4.0"

HTML 4.01 refers to RFC 1808 for this purpose, while xml-stylesheet
refers to RFC 2396. The latest version of this document is RFC 3986.
The process of turning relative references into absolute ones is
different for each of these documents. As such, even if the state-
ment above were meaningful, it is not much of a help in addressing
the problem I've pointed out.

>Turning to HTML 4.0 [2] we find:
>
> "User agents must calculate the base URI according to the following
>  precedences (highest priority to lowest):
>
> "1. The base URI is set by the BASE element.
>
> "2. The base URI is given by meta data discovered during a protocol
>     interaction, such as an HTTP header (see [RFC2616]).
>
> "3. By default, the base URI is that of the current document. Not all
>     HTML documents have a base URI (e.g., a valid HTML document may
>     appear in an email and may not be designated by a URI). Such HTML
>     documents are considered erroneous if they contain relative URIs and
>     rely on a default base URI."
>
>Clause 1 clearly don't apply, but clauses 2 and 3 seem to me to give a
>complete answer.

It is not clear to me that 1) does not apply e.g. in case of a XHTML
document using both xml-stylesheet and <base/> or whethet such a
document could possibly be conforming as HTML 4.01 requires that no
relative references are used prior to the <base/> element (if any);
of course, that restriction applies only to elements, not processing
instructions. In any case, neither the XHTML nor the xml-stylesheet
specifications explain how to process this case.

>I'm sorry to be dense, but I can't think of a document in which the
>XML Base quote above "does not apply" to an xml-stylesheet PI --
>Bjoern, could you please illustrate your point?

Let F be a XML document format for which the specification does not
normatively reference the XML Base specification and let D be a XML
document that conforms to F with a xml-stylesheet PI that conforms
to the xml-stylesheet specification. Since XML Base applies only to
docuemnt formats for which the specification normatively references
XML Base, it does not apply to D. A simple example is

  <?xml-stylesheet href='foo'?><x/>

Now let F be the SVG 1.1 specification and D be an SVG 1.1 document
with a xml-stylesheet processing instruction. We can now argue that,
because SVG 1.1 normatively references XML Base, that specification
applies to the PI in D. We can also argue that because the xml-
stylesheet specification does not normatively reference XML Base,
that specification does not apply to the PI in D.

The XML Base specification does not explain whether, in case of
processing instructions, the requirements apply regardless of what
the specification of the processing instruction refers to XML Base,
but it is very clear that it does not apply when there is no such
normative reference at all.

But this is all irrelevant, the xml-stylesheet specification does
not define what the base resource identifier for any given xml-
stylesheet processing instruction is, it has to define that, and
simply adding the definition to the errata document is much, much
less work than continuing this discussion.
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 

Received on Monday, 2 October 2006 09:04:37 UTC