[Pmwiki-users] Re: Case Insensitive URLs

Patrick R. Michaud pmichaud
Fri Apr 2 20:48:50 CST 2004


On Fri, Apr 02, 2004 at 08:18:19PM -0600, Eric Celeste wrote:
> > Drawback #1: What if you have pages called ITCouncilMinutes and
> > ITcouncilMinutes?

The biggest issue to this is determining how the page title should
be displayed at various points that aren't wiki markup -- i.e., at
the top of a page or in search results.  I.e., I'm not sure that one
would want to see the output of search results as

pmwiki/
   audiences
   changelog
   custommarkup
   documentationindex
   patrickmichaud
   phpsafemode

or to have the page title displayed in lowercase.

There are a couple of possible workarounds to this, both with some
undesirable side-effects:
   1. PmWiki could (and already does) store a page's "official 
      case-sensitive name" along with the page, and use that when
      producing a page title.  The downside is that this sometimes
      requires an extra page read to get the correct name, as the
      filename is no longer sufficient, and it would also be possible
      for the official name's case to be subverted in a variety of ways.
   2. For the page's title, the system could simply choose to use the
      case given in the page name that was used to access the page.
      This makes things a bit "weird" overall as the page title
      seems to change depending on how it was accessed (and this approach
      doesn't resolve the search problem at all).

I suspect the real solution will be to (finally?) allow pages to have titles
that are separate from the page's name (with the default title being the
page's name if not otherwise specified).  Unfortunately, something like
this will probably require a major release, as the $Title variable has
traditionally been defined as being the name of the page.

> That, and the
> potential backward-incompatibility it induces, would argue for this being an
> option, a switch we could throw in config.php, rather than the default
> behavior. I would love to throw the "$CaseInsensitiveURL=1" switch if it
> existed.

I actually considered case-insensitivity when starting PmWiki, and
ultimately decided that starting with case-sensitive names and possibly
switching to case-insensitive ones at some point in the future would
cause less hassles than the other way around.  If the search/titling
problems described above can be satisfactorily resolved, I see no problem
with introducing an $EnableCaseSensitiveNames=0 parameter to cause this
behavior.  Also, note that on some operating systems such as OS/X and
Windows, PmWiki's page references are already case insensitive because the
underlying operating system is case insensitive.  AFAIK, neither PmWiki
nor its users have had any real issues with usability in such environments.

Pm



More information about the pmwiki-users mailing list