[pmwiki-users] SpellChecker on a Farm

Pico pmwiki at ben-amotz.com
Sun Sep 17 11:30:59 CDT 2006


Scott Connard wrote:
> Pico wrote:
> 
>> JB wrote:
>>
>>> Pico wrote:
>>>
>>>> I revised your edit to the documentation because there was no need to
>>>> provide different sets of include lines for farms and non-farms; all
>>>> installs can use the same line:
>>>>
>>>> include_once("$FarmD/cookbook/spellchecker.php");
>>>>
>>>
>>>
>>> I do not think that is right.  Sometimes a local wiki which uses farm
>>> recipes has one recipe that only it uses. The local wiki recipe can be
>>> located in the local wiki cookbook directory.  Since the local wiki is
>>> in a farm environment using "$FarmD" will cause it not to find the
>>> local recipe.  This is also confusing to new users (like I was the
>>> first few months I was using PMWiki.)
>>>
>>> So the example you explained above works for
>>>
>>>     local wiki using local recipe(s)
>>> or
>>>     local wiki using farm recipe(s)
>>>
>>> but will not work for
>>>
>>>     local wiki using both local recipe(s) AND farm recipe(s)
>>>
>>>
>>> Please change it back.
>>>
>>>
>>>
>>
>> I don't agree that this (and, for that matter, every other recipe)
>> should have two different installation instructions for farm and
>> non-farm installs just because someone with a farm might want to
>> physically place the recipe in a field, instead of simply invoking it
>> from the local field config.
>>
>> Does anyone think that JB has the better approach here and, if so,
>> should it be adopted for all recipes?
> 
> My feeling is that it would certainly be nice if all recipes were 
> consistent.  Unfortunately the three different cases cited by JB lead to 
> at least two different solutions...I don't think it's possible to 
> engineer a single solution for all three cases.  Rather than documenting 
> all cases in EACH recipe, I would think we'd want to document some 
> standard case in all of the recipes and then explain the other option(s) 
> very clearly in the Wiki Farm documentation.
> 
Sounds like a common sense approach.

> Since I run a Wiki Farm, using "$FarmD" makes the most sense to me - it 
> works for non-farm implementations and a "normal" farm implementation 
> where all wikis want the same standard features.  The Wiki Farm with 
> local features could be clearly documented in one place in the Wiki Farm 
> documentation.
> 
> What concerns me a little more is the need to edit the source to change 
> "$PubDirUrl" to "$FarmPubDirUrl" for the SpellChecker script.  Is this 
> required for many other cookbook scripts?  Is there a way to engineer a 
> common solution for this problem?  Should ALL code referencing 
> $PubDirUrl look in $PubDirUrl first and then failing that look in 
> $FarmPubDirUrl (if it is different than $PubDirUrl)?
> 
I think the change in the script should work for farm and non-farm 
installs.  According to the documentations:

$FarmPubDirUrl
is the url that refers to the pub directory for an entire farm. It 
defaults to the same value as $PubDirUrl.

PmWiki/PathVariables

So if it defaults to $PubDirUrl, then it should work for local installs 
(just like the config.php include reference to farm works).  Test it out 
if you want.

Anyway, Pm could tell us in a second, but he's probably pretty busy 
with the Pdata aware pagelist (I hope...)

Pico


-- 

         __  /
        /   /
       /___/ _/  ___/  __  /
      /      /  /     /   /
    _/     _/  ____/ ____/

 >>>===pmwiki at ben-amotz.com===>




More information about the pmwiki-users mailing list