[pmwiki-users] Totally Perplexed by Farming and Fields...

Joachim Durchholz jo at durchholz.org
Mon Jan 23 03:09:11 CST 2006


gdb at soundchasers.com schrieb:
> Okay - so, I started thinking about how to re-organize the site.  The 
> idea that
> I came up with was to use the farm feature to create fields for each of the
> major pieces of the site: news, blog, gallery, links, etc.  Then, create a
> system field (called sys), and organize all the adminstrative forms, indexes,
> etc. by group for each of the fields.  (IE, for the blog field, there would be
> a blog.* group in the sys field that would store forms, and indexex, etc.)  My
> hope was / is that by organizing things this way, I could minimize the impact
> to the individual fields when re-organizing things in the sys field (yeah, it
> would still require some fancy footwork, but I think it can be done...)  Also,
> this brought about the added bonus of being able to customize the 
> templates for
> each field, and some other niceties.

I think you can do this all using just groups.
Fields are more for wikis with a common administrator but unrelated 
contents, or so I understand.

> Question: is it possible to change the page used for the sidebar "on-the-fly">
> Maybe through <group>.php?  IE, if I wanted to have a <group>.sidebar replace
> site.sidebar for each group in the wiki, would this be possible?

No need for scripting: just set up a page named <group>.SideBar. 
Site.SideBar is just the default in case there's no <group>.SideBar.

In an emergency, you can do things like
   if ($group == 'some_group') {
     ... do some group-specific setup here ...
   }
in your config.php. (I haven't checked whether $group is really the 
correct variable name.)
(I just saw that there seems to be a way to set up a per-group 
configuration file. Just drop a file named <group>.php into the local/ 
directory. Seems to be a new feature that was introduced in the last few 
months.)

HTH
Jo




More information about the pmwiki-users mailing list