[pmwiki-users] Clean URLS cookbook question

Patrick R. Michaud pmichaud at pobox.com
Sat Feb 4 14:01:54 CST 2006


On Sat, Feb 04, 2006 at 12:47:27PM -0700, H. Fox wrote:
> On 2/3/06, H. Fox <haganfox at users.sourceforge.net> wrote:
> > I'm interested to see what those cases are.  Mainly I was going for "a
> > method that works reliably" as a baseline.
> 
> I added an introduction to the to the examples.  The reason is to
> clarify the cases that *are* covered (where the rewritten "root URL"
> is in the same directory, the directory above, and the document root).
> 
> http://www.pmwiki.org/wiki/Cookbook/CleanUrls#examples

It's looking very good.

The CleanUrls page currently has the information about $PubDirUrl
and $UploadUrlFmt in a separate section at the bottom of the page.
Since using CleanUrls nearly always requires setting these
variables, I think they need to go in the local/config.php
examples above (even if it's repetitious), otherwise they'll
get overlooked.

AFAIK it's rare that $UploadDir has to be changed as a result of
CleanUrls, so I'd leave that one out entirely.

Lastly, there are a couple of approaches for doing clean urls
that don't require mod_rewrite, and we ought to document those
somewhere -- probably on separate pages.  Any idea how we should
connect those to the existing page?  I'm thinking that CleanUrls
should indicate somewhere early in the page that Apache's mod_rewrite
is the most popular approach to clean urls, but for sites that aren't
running Apache or that don't have access to mod_rewrite, there
are some other alternatives available.

The other two useful approaches are (1) add Alias entries in
httpd.conf, and (2) create a PHP script that doesn't have the ".php"
extension in it but is able to call PmWiki.

Perhaps CleanUrls should itself be an overview page, with a
description of the approaches and links to CleanUrlsRewrite, 
CleanUrlsAlias, and CleanUrlsScript, or something like that.
Or, we can leave CleanUrls as being focused on mod_rewrite
(since it's the most popular approach), but if we do that there
should be easy-to-find links to the other approaches (even if
they're just placeholder links until those documents are written).

Pm




More information about the pmwiki-users mailing list