Subject: [Uri-review] A proposal for specifying the 'view-source' URI scheme

From: Mykyta Yevstifeyev <[email-masked]>
Date: Mon, 11 Apr 2011 09:43:23 +0300

Hello folks,

I'm writing to ask an advice on one of the URI schemes.  I've noticed
that the 'view-source' URI scheme, which has been in use for quite a
long time (starting with Internet Explorer 4), is not officially
regsitered in the IETF.  The situation is nearly the same as with
'about' scheme.  Therefore I'd like to ask whether specifying this
scheme makes any sense?  Will this be useful?

Please feel free to express your thoughts on this topic directed to me
and/or to the uri-review list.

All the best,
Mykyta Yevstifeyev

---

From: Eric Johnson <[email-masked]>
Date: Mon, 11 Apr 2011 14:59:26 -0700

How fascinating.

It strikes me that the point of this URL is to signal to a browser that 
it should serve content available via HTTP (and others?) in a particular 
presentation. Logically, then, this really should fall to the 
presentation layer (HTML).

Why use a URI to accomplish that? In HTML, there could just as easily be 
an attribute on an <a> tag. If I right-click a link, the browser could 
easily just show me a "browse-source" option.

Some URIs aren't resources in the sense of HTTP - for example, "tel:", 
"email:", the one I've been working on ("jms:"), etc - so this doesn't 
seem like the view-source can be generally prefixed to just anything.

My take: it doesn't make sense to standardize.

-Eric.

On 4/10/11 11:43 PM, Mykyta Yevstifeyev wrote:
> _______________________________________________
> Uri-review mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/uri-review

---

From: Mykyta Yevstifeyev <[email-masked]>
Date: Tue, 12 Apr 2011 17:47:38 +0300

12.04.2011 0:59, Eric Johnson wrote:
> How fascinating.
>
> It strikes me that the point of this URL is to signal to a browser 
> that it should serve content available via HTTP (and others?) in a 
> particular presentation. Logically, then, this really should fall to 
> the presentation layer (HTML).
>
> Why use a URI to accomplish that? In HTML, there could just as easily 
> be an attribute on an <a> tag. If I right-click a link, the browser 
> could easily just show me a "browse-source" option.
>
Eric,

What you say regarding the in-bound browsers facilities to show the 
source of some document is right.  However I do not propose something 
new - 'view-source' URIs, even not used as widely as eg 'http' URIs, are 
used.  This is a fact.  Moreover, I do not propose to standardize it as 
Proposed Standard - I suggest having some formal record at the IETF and 
in the IANA registry for this scheme, possibly in Informational RFC.

Mykyta Yevstifeyev

---

From: "Martin J. Dürst" <[email-masked]>
Date: Wed, 13 Apr 2011 15:28:18 +0900

> presentation layer (HTML).

Well, you can of course use HTML to present source code, by e.g. putting 
it into a <pre> element and escaping '<' and friends.

But the official way to serve source as source is to give it a content 
type of text/plain. The problem with that is that some if not most 
browsers, because of the past dynamics between badly setup servers and 
bugwards compatible browsers, tend to ignore the text/plain media type 
under certain  circumstances. For details, please see 
http://tools.ietf.org/html/draft-abarth-mime-sniff.

> easily just show me a "browse-source" option.

Or the user could press cntl-u for 'view source'.

> seem like the view-source can be generally prefixed to just anything.

Strictly speaking, that's not necessary at all. If it makes sense in 
some cases, it may be worth using.

> My take: it doesn't make sense to standardize.

I'd agree to be careful and look at what other browsers do, and check 
with some browser vendors whether they care about it, before spending 
needless standardization cycles.

Regards,   Martin.

---

From: Peter Saint-Andre <[email-masked]>
Date: Wed, 13 Apr 2011 06:07:31 -0600

> Or the user could press cntl-u for 'view source'.

That was my thought, too.

> needless standardization cycles.

+1

Peter

-- 
Peter Saint-Andre
https://stpeter.im/

---

From: Graham Klyne <[email-masked]>
Date: Fri, 15 Apr 2011 14:02:56 +0100

Martin,

I'm guessing your comments are missing Mykyta's point.  Without knowing all the 
  details, I'm guessing that a view source URI scheme *has been implemented* as 
a mechanism for displaying page source (cf. 
http://en.wikipedia.org/wiki/View-source_URI_scheme), and Mykyta is asking if it 
should be documented and registered as provisional.

This is separate from any issue of its desirability or recommendation that it be 
used.

I don't have any especially strong feeling about this.  On balance, I think 
having its existence documented is not a bad thing, but not an activity I'd be 
inclined to invest a lot of effort in.  Maybe just a registration template with 
a link to the Wikipedia page?

#g
--

Peter Saint-Andre wrote:
> ------------------------------------------------------------------------
>

---

From: Eric Johnson <[email-masked]>
Date: Fri, 15 Apr 2011 09:38:08 -0700

I guess my take on it, which seems to align with Martin's, is that 
whatever intent behind the view-source URI scheme, it appears to solve 
the problem in the wrong way. The functionality can be handled at the 
presentation/application layer in the browser, not at the extremely 
low-level of a URI scheme. And of course, if you want to view source, 
currently you can simply do Ctrl+U, or your browser's equivalent.

If it is flawed, then perhaps it is sufficient to have a Wikipedia page, 
and not have it documented at the IETF?

-Eric.

On 4/15/11 6:02 AM, Graham Klyne wrote:
> Martin,
>
> I'm guessing your comments are missing Mykyta's point.  Without 
> knowing all the  details, I'm guessing that a view source URI scheme 
> *has been implemented* as a mechanism for displaying page source (cf. 
> http://en.wikipedia.org/wiki/View-source_URI_scheme), and Mykyta is 
> asking if it should be documented and registered as provisional.
>
> This is separate from any issue of its desirability or recommendation 
> that it be used.
>
> I don't have any especially strong feeling about this.  On balance, I 
> think having its existence documented is not a bad thing, but not an 
> activity I'd be inclined to invest a lot of effort in.  Maybe just a 
> registration template with a link to the Wikipedia page?
>
> #g
> -- 
>
>
>
> Peter Saint-Andre wrote:
>>>> that

---

From: Graham Klyne <[email-masked]>
Date: Fri, 15 Apr 2011 21:03:01 +0100

Part of the reason for introducing the *provisional* scheme registry was to 
provide a single point where developers could find out about known URI schemes 
deployed or under consideration, irrespective of how good or bad they may be. 
The other option, which we'd like to avoid, is to have lots of invented schemes 
in the wild that developers are not aware of, which in turn leads to potentially 
conflicting uses of a given scheme name.

And in some cases, they might even be registered with an exhortation like "DO 
NOT USE THIS".

#g
--

---

From: Bjoern Hoehrmann <[email-masked]>
Date: Fri, 15 Apr 2011 23:07:31 +0200

>scheme makes any sense?  Will this be useful?

It is very rare these days that I come across the scheme, I would rather
see effort spent on `irc`, `jar`, and maybe `magnet` and `rtmp`, but in
that list I suppose `view-source` would come next, mostly for historical
interest, so if you are interested in that and not in the others, sure.

(The URI scheme registry is actually in a fairly good shape if you ig-
nore all the application-specific schemes, and there is value in making
it reasonably complete).
-- 
Björn Höhrmann · mailto:[email-masked] · http://bjoern.hoehrmann.de
Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/

---

From: Alexey Melnikov <[email-masked]>
Date: Fri, 15 Apr 2011 23:15:27 +0100

Graham Klyne wrote:

> Part of the reason for introducing the *provisional* scheme registry 
> was to provide a single point where developers could find out about 
> known URI schemes deployed or under consideration, irrespective of how 
> good or bad they may be. The other option, which we'd like to avoid, 
> is to have lots of invented schemes in the wild that developers are 
> not aware of, which in turn leads to potentially conflicting uses of a 
> given scheme name.

+1. It is much better to document a URI scheme as provisional, 
especially if it is deployed.

> And in some cases, they might even be registered with an exhortation 
> like "DO NOT USE THIS".

Indeed.