W3C home > Mailing lists > Public > uri@w3.org > October 2007

Re: URI Templates, percent-encoding, bnfs and working code

From: Joe Gregorio <joe@bitworking.org>
Date: Mon, 15 Oct 2007 08:31:52 -0400
Message-ID: <3f1451f50710150531l33a14540h48b0b1acda178a06@mail.gmail.com>
To: "Mark Nottingham" <mnot@mnot.net>
Cc: uri@w3.org

On 10/15/07, Mark Nottingham <mnot@mnot.net> wrote:
>
> On 13/10/2007, at 12:22 PM, Joe Gregorio wrote:
>
> >    What if the *only* way to get a reserved character into
> >    the final URI was through templating expansions?
>
> [...]
>
> > So what does this experiment look like? Let's be as draconian as
> > possible:
> >
> >    1. Convert Unicode template values to UTF-8.
> >    2. Percent-encode all characters outside unreserved.
>
> [...]
>
> > Does it work? Let's try all our previous examples:
> >
> > My blog template works out fine:
> >
> >       http://bitworking.org/news/{entry}
> >       entry := '240/Newsqueak'
> >       http://bitworking.org/news/240/Newsqueak

Ah, my bad, that should have been:

       http://bitworking.org/news/{&/|entry}
       entry := ['240', 'Newsqueak']
       http://bitworking.org/news/240/Newsqueak


   Thanks,
   -joe

-- 
Joe Gregorio        http://bitworking.org
Received on Monday, 15 October 2007 12:32:02 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 13 January 2011 12:15:37 GMT