Re: file: URIs without host

On Thu, 04 Oct 2007 14:43:05 +0100, Dan Connolly <connolly@w3.org> wrote:

> On Thu, 2007-10-04 at 14:34 +0100, Jeremy Carroll wrote:
> [...]
>> ====
>>
>> Jena's RDF/XML side:
>>
>> However, a use case for such file URIs would be that we wish to create a
>> zip file including a complete application, which includes references to
>> data in the zip. When we unzip we want the references to work,
>> independent of both the machine or the directory.
>
> That case is why we have relative URI references; drop the scheme
> altogether if you want to refer to "nearby" things.

Yes, but if you drop the scheme, then you inherit the current scheme.

If you are in the middle of an http page and write <a href="foo"> then it  
means look for the page 'foo' at the same level as the current page, but  
STILL USING HTTP. If you want to insert a file: URL in the middle of an  
http page (in general, a stupid thing to do), then a relative URI won't  
work.

But in the example mentioned, with that zipped application, and it happens  
to contain an internal ./doc directory with all the documentation in html,  
then indeed all the URLs within the documentation are relative, and are  
likely to be accessed using a file: URL when examining the doco on the  
local machine. Packages are routinely distributed in that sort of format.

It is only the rare cases where you want to change scheme at the same time  
as using a relative URL that the problem under discussion arises.

-- 
Charles H. Lindsey ---------At Home, doing my own thing------------------------
Tel: +44 161 436 6131                       
   Web: http://www.cs.man.ac.uk/~chl
Email: chl@clerew.man.ac.uk      Snail: 5 Clerewood Ave, CHEADLE, SK8 3JU, U.K.
PGP: 2C15F1A9      Fingerprint: 73 6D C2 51 93 A0 01 E7 65 E8 64 7E 14 A4 AB A5

Received on Wednesday, 10 October 2007 19:45:38 UTC