[pmwiki-users] lower case URLs

Patrick R. Michaud pmichaud at pobox.com
Tue May 30 19:50:15 CDT 2006

On Wed, May 31, 2006 at 01:10:01AM +0200, Clemens Gruber wrote:
> Hello,
> I've got an existing website with URLs only in lower cases. Now I'd like 
> to use PmWiki for this site. However the adresses should be persistent 
> (s. "Cool URIs don't change", Tim Berners-Lee, 
> http://www.w3.org/Provider/Style/URI). How can I configure PmWiki to 
> produce URL in lower cases?

Short answer:  It's likely to be fairly difficult to do this.
The problem is that given a lowercase url, it's not always easy
to find the (mixed-case) page name that corresponds to the lowercase
request.  Or, if we assume that page names are all lowercase, then
it's hard to do things such as automatically spacing wikiwords.

Intermediate answer:  The issue of removing WikiWord restrictions
from page names has come up frequently enough that I'm actively 
looking for ways to resolve it.  If we were starting from scratch,
it'd be easier (but not necessarily "easy"); as it is now I 
desperately want to make sure that any change I introduce here
(1) solves a wide class of problems, and (2) doesn't break anything
in the process.  In other words, I don't want a bandage solution
that 'solves' things for a specific case, and I want to make sure
that for existing sites things can continue to work exactly as they
have before.  Yes, it's a tall order, but I think it's doable.  
I just need more time to work out all of the dependencies.

Long answer -- my thoughts on "Cool URIs don't change":

First, I should state categorically that I very much agree with the
principles outlined in "Cool URIs don't change".  But unfortunately
I think this was written in a time before there was widespread use
of automated tools for generating web pages.  The article really
presumes that pages are static entities that can be easily managed
by hand.

It's nice to posit that "Cool URIs don't change", but this also means
that someone has to be perfectly prescient about what tools might be
used to maintain a site in the future.  Or to forego the use of any
tools that doesn't exactly support whatever decision you might've
made in the past.  TimBL alludes to this in the section that reads

    We would like to [keep the same urls], but we just don't have 
    the right tools.

    Now here is one I can sympathize with. I agree entirely. 
    What you need to do is to have the web server look up a 
    persistent URI in an instant and return the file, wherever 
    your current crazy file system has it stored away at the 
    moment. You would like to be able to store the URI in the 
    file as a check, and constantly keep the database in tune 
    with actuality. You'd like to store the relationships 
    between different versions and translations of the same 
    document, and you'd like to keep an independent record of 
    the checksum to provide a guard against file corruption by 
    accidental error. [...] You need to be able to change things 
    like ownership, access, archive level security level, and 
    so on, of a document in the URI space without changing the URI.

    Too bad.  But we'll get there. [...]

So, even W3C recognizes that this is an ideal to be striven for,
but one that cannot always be reached.

The standard approach is to build redirects that keep the old URLs
functioning and redirect browsers to the new location.


More information about the pmwiki-users mailing list