# Re: URLs, URIs, and references

Larry Masinter (masinter@parc.xerox.com)
Mon, 24 May 1993 17:16:09 PDT

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: Keith Moore: "Re: Some URLs look like URNs already"
- Previous message: Brian Capouch: "Re: URLs, URIs, and references"
- Maybe in reply to: Larry Masinter: "URLs, URIs, and references"
- Next in thread: Dirk Herr-Hoyman: "Re: URLs, URIs, and references"

    To: uri@bunyip.com

    Subject: Re: URLs, URIs, and references

    From: Larry Masinter <masinter@parc.xerox.com>

    Message-Id: <93May24.171617pdt.2741@golden.parc.xerox.com>

    Date: 	Mon, 24 May 1993 17:16:09 PDT

Re pushing other information into URCs:

Well, I'd almost want to give into this, but I really think the 'type'
of data is different from the other extrinsic pieces of contextual
information like author, keywords, or even dates. In the current URL
spec, for the most part, the content-type already *is* coded in the
URL, just in an ad-hoc way: in the type code in gopher URLs, in the
file extension for ftp URLs etc.

Looking at the code for various w3 implementations, you see a great
deal of ad-hoc-ery trying to decode what the 'current type of this URL
might be'.
...
if (*extension == '.') {
return 0==strcmp(".html", extension) ? WWW_HTML
: 0==strcmp(".rtf", extension) ? WWW_RICHTEXT
: 0==strcmp(".txt", extension) ? WWW_PLAINTEXT
: WWW_PLAINTEXT; /* Unrecognised, try plain text */
...
(defvar w3-viewer-alist
(append
'(
("\\.ps$" . "ghostview -")
("\\.\\(jpg\\|xbm\\|gif\\|ras\\|ppm\\)$" . "xv -perfect -")
("\\.mpeg$" . "mpeg_play -")
("\\.\\(au\\|snd\\)$" . "play -")
)
auto-mode-alist)
"*An assoc-list of viewers for specific file extensions.")
...
(I'm sure stuff like this exists in every www implementation).

================================================================
I'd just like to clean up the current practice, because this code
looks like it is hard to maintain and likely to be unreliable. I'm
more wary of adding dates and other kinds of things to the URLs, just
because the current implementations usually get along without them,
and I'm not sure how I'd use them if I had them.

- Next message: Keith Moore: "Re: Some URLs look like URNs already"
- Previous message: Brian Capouch: "Re: URLs, URIs, and references"
- Maybe in reply to: Larry Masinter: "URLs, URIs, and references"
- Next in thread: Dirk Herr-Hoyman: "Re: URLs, URIs, and references"