[pmwiki-users] Clean URLs - how to make them even shorter?

Patrick R. Michaud pmichaud at pobox.com
Mon Feb 14 11:44:20 CST 2005


On Sat, Feb 12, 2005 at 02:32:01PM -0500, Matt Simpson wrote:
> How do I do I create a clean URL down to the root (per discussion below) for
> a field of a wiki
> farm, assuming that the field has http://wikifielddomain.com, with field.php
> installed within /pmwiki on that domain.
> 
> I tried a number of things be don't seem to get it right.  I confirmed that
> I do allow options override using .htaccess config.

In the root of wikifielddomain.com (i.e., not in the pmwiki/ dir), create
.htaccess as:

    RewriteEngine on
    RewriteRule ^([A-Z].*) /pmwiki/field.php?n=$1 [L,qsappend]
    RewriteRule ^$ /pmwiki/field.php

In your field's config.php file, set:

    $ScriptUrl = 'http://wikifielddomain.com';
    $PubDirUrl = 'http://wikifielddomain.com/pmwiki/pub';

I'm probably forgetting a couple of items but this ought to get
things started in the right direction.  

Pm



More information about the pmwiki-users mailing list