W3C home > Mailing lists > Public > uri@w3.org > January 2002

Re: Base URIs vs. Document URIs.

From: Al Gilman <asgilman@iamdigex.net>
Date: Fri, 11 Jan 2002 12:11:00 -0500
Message-Id: <Version.32.20020111120011.03fdaa30@pop.iamdigex.net>
To: "Jason Diamond" <jason@injektilo.org>, <uri@w3.org>
At 11:46 AM 2002-01-11 , Jason Diamond wrote:
>Thanks, Paul.
>> >Is there any way to resolve something like "#s" against the base URI and
>> >the document URI?
>> I'd suggest that you shouldn't be calling resolveURI at all in the case
>> that the relative URI reference is merely a fragment identifier.  There
>> is nothing to resolve.
>I need some function that accepts a URI reference and returns a URI. If you
>know of a more appropriate name than resolveURI then I would be happy to use
>it. I only chose resolveURI since Appendix C uses the term resolve and it
>includes the example of the URI reference "#s".
>I only asked the question out of pure curiosity--I don't think I would ever
>need to do it.
>But just so I understand, let's say that my document URI is

'Document URI' is your term and not defined in the standard notions.

This is the URI by/with/from which you recovered a representation which
a BASE at:

and my base URI is
><<http://example.org/base.xml>http://example.org/base.xml> and I want to
resolve to

You want to refer to ...

the only URI reference that I can
>think of that would get me what I want is <base.xml#fragment> 

The _minimum_ URL-reference you can...

>because if I
>used <#fragment>, it would get resolved to
#fragment>. Is this correct?

The latter is correct.

Other, longer URI-references work, too, starting with
"/base.xml#fragment".  So
it's not the only URI-reference you can use.  

And '.' doesn't work for _ibid_ for documents, just for path segments.  And in
the case you have painted here where the historical URI and base URI are
different, 'ibid' would be ambiguous.  So the lexically shorter form is bound
to the more local resolution, as is fitting.


>I really appreciate your helping me to understand these issues!
Received on Friday, 11 January 2002 12:11:10 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:25:03 UTC