@Adys:
As I understand, Justin's "remove all slashes" was just a hypothetical
example.

@Justin:
I agree that it's not about avoiding an illusion. It's just ugly and
unhandy, that's it. And yes, most non-django systems out there that I
can think of do either have crappy old school urls, or nice ones
without a trailing slash.

---------

(preaching mode on)
Why care about URLs anyway? They should look nice in the address bar,
yes.. but to see their real relevance, you should think about what
people might do with them!
- type it: "example.com/foo/bar/"
- dicate it on the phone: "example dot com slash foo slash bar slash"
- store it in a bookmark
- send it in an email, or put it in a forum post
- look at a list full of urls (such as web search results)
- make sense of the hierarchic structure of a website: Slashes are
useful for that, but not the one in the end!

So really, we should be happy about any meaningless symbol we can get
rid of!
But I think we all agree on that so far. Let's see what comes out!

Btw, I'm quite new to django, I was a bit surprised to see this
append_slash thing. Otherwise, it looks nice.

donquixote



On Jun 15, 11:19 pm, Adys <adys...@gmail.com> wrote:
> Are you sure you understood the original proposal?
> No one here wants to remove all slashes! Just "cleanup" the url:
> Clean:http://example.com/foo/bar
>
> Uncleanhttp://example.com/foo/bar/http://example.com/foo///barhttp://example.com///foo//////bar///
>
> The last two would be a more aggressive setting.
>
> On Jun 15, 6:24 pm, Justin Myers <masterb...@gmail.com> wrote:
>
>
>
> > I can appreciate the need for this setting (among other things, it
> > might make migrating URLs from systems where this is more standard
> > (e.g., Drupal) simpler), but I wouldn't go so far as to talk about an
> > "illusion".
>
> > Unless we're proposing to remove all slashes from all URLs--which is
> > certainly possible with our URL system--there's always going to be
> > some hint of that, but I think the slashes represent a hierarchy more
> > than they do a directory structure. Sure, directories were a big
> > influence on why the slashes ended up there in the first place, but I
> > don't think anyone is sufficiently taken by this "illusion" that they
> > think there's actually a file called "2b6a459329fe498a" in a folder
> > called "thread" when they read this discussion...
>
> > -Justin
>
> > On Jun 14, 12:53 am, "M. N. Islam Shihan" <mnis4...@gmail.com> wrote:
>
> > > +1
>
> > > I also like the remove_slash version of urls over the append_slash  
> > > version as the trailing slash creates a directory structure illusion  
> > > which is not true.
>
> > > Cheers
> > > Shihan
>
> > > On Jun 14, 2009, at 11:12 AM, donquixote <klabaut...@googlemail.com>  
> > > wrote:
>
> > > > Ok, I know similar questions have been asked about the trailing slash
> > > > before. See
> > > >http://groups.google.com/group/django-developers/browse_thread/thread...
>
> > > > My proposal is a little different:
> > > > - I agree there should be only one url for each page. Any alias urls
> > > > should be redirected.
> > > > - I think that trailing slashes look ugly, and should be avoided for
> > > > good style.
>
> > > > Nice (i):
> > > >http://mysite.org/members/emil
> > > >http://mysite.org/members/emil/contact
>
> > > > Not nice (ii):
> > > >http://mysite.org/members/emil/
> > > >http://mysite.org/members/emil/contact/
>
> > > > Even worse (iii):
> > > >http://mysite.org/members/emil////////////
> > > > etc
>
> > > > Or worst (iv):
> > > >http://mysite.org////members////emil////////////
>
> > > > So, ideally I want the (ii) and (iii) and (iv) type of urls (with more
> > > > slashes than needed) redirected to the first type of urls (with no
> > > > trailing slash, and no duplicate slashes). For the duplicates I don't
> > > > care that much, most important is the case (ii) with one trailing
> > > > slash.
>
> > > > And this is how I imagine this to work:
> > > > - In addition to the existing option of append_slash, we get one more
> > > > option, which is remove_slash.
> > > > - With the setting enabled, for any given url there will be two
> > > > versions computed: One reduced version without duplicates and without
> > > > trailing slash, and one version without duplicates but with one
> > > > trailing slash appended.
> > > > - The dispatcher will give both versions a try.
> > > > - If the original url had a trailing or duplicate slash, and no other
> > > > redirect directive has been triggered, the request will be redirected
> > > > to the reduced version.
> > > > - If the original url was "clean", django can now execute the action
> > > > determined by the dispatcher.
>
> > > > I think this will be more useful than the append_slash mechanic.
>
> > > > Thanks!
> > > > donquixote
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to