[pmwiki-users] Oh so close...

George gdb at soundchasers.com
Sun Aug 13 16:05:03 CDT 2006

Hello everyone,

Okay, first, a confession: I stopped using pmWiki.  Yes, I did. The 
reason: I wasn't able to make the leap to customizing my site to do 
something I really needed pmWiki to do for me. Don't get me wrong, this 
wasn't a failing of pmWiki. The available solutions didn't do what I 
wanted, and  a custom solution was more involved than I could handle.

Having said that, none of the other solutions I have looked at / used 
have really fit my needs either.  So, I decided to download a current 
version of pmWiki and start playing with it.  I really want to move back 
to pmWiki, it's the best tool that I've worked with overall.

Having said this, my evaluation of the current version of pmWiki has 
left me *extremely* excited.  From all appearances, all the tools I want 
are now in the pmWiki core.  However, there is still one piece missing.  
It's my hope that maybe someone here can help me with a way to actually 
implement the missing piece.

The big issue I had before was having to manually maintain indices for 
WikiTrails and other index pages. The fact was I had literally hundreds 
of pages, split across multiple groups, with WikiTrails for each group 
(in a couple of cases, I had multiple WikiTrails in use for different 
"sub" groups).  And, then, for some pages, I would have to manually edit 
the page to (:include :) new pages when I added a new page to the group.

Now, it appears that (:pagelist :) can generate the output I want, and 
even format in whatever manner I want it formatted through custom 
formatting.  This completely removes the need for using (:include :)! 
(YAY!!!)  However, what it doesn't do, is give me an automatic way to 
generate the index for a WikiTrail.

But, I am thinking there must be a way to do this now.  (:pagelist :) is 
powerful enough to generate the output that is needed.  What is needed 
is just a mechanism that could save the output from (:pagelist :) to the 
WikiTrail index (ie, replace the old contents of the WikiTrail index 
page) whenever a page is updated or created.

I was thinking this might be possible by setting up a custom edit form 
for each group, and then having a local php file for the edit page that 
could accomplish two goals:

(a) take the output from the edit form, and create the new page.
(b) go through the process of calling (:pagelist :) from the pmWiki 
core, and take the resulting array (I ???think??? it's going to be an 
array), and re-write the WikiTrail index.

A little more solid example:

abc.NewPage -- form to create a new page in group abc
abc.TrailIdx -- page containing the WikiTrail index
local/abc.NewPage.php -- code to create the new page (from the values in 
the abc.NewPage), and update the abc.TrailIdx with the output from 
calling the (:pagelist :) php code directly.

Okay - so I have this idea,  but I don't have a clue  how to go about 
implementing it.  Is there a way to do it?  Have I given enough detail 
for this to make sense?

// George

More information about the pmwiki-users mailing list