[pmwiki-users] New recipe: Fox

Patrick R. Michaud pmichaud at pobox.com
Tue Dec 19 13:31:47 CST 2006


On Tue, Dec 19, 2006 at 07:20:17PM -0000, marc wrote:
> Hans said...
> > Tuesday, December 19, 2006, 6:24:18 PM, marc wrote:
> > 
> > > So, the question is - probably for Pm - in what circumstances can 
> > > UpdatePage receive identical input, yet produce different results?
> > 
> > I take it that your problem with page save is only with fox.php, and
> > you can save pages fine from the normal edit window.
> 
> Yes.
> > 
> > I don't know if calling the Lock function does make a difference,
> > i.e. HandelEdit calls Lock before calling UpdatePage, in fox.php Lock
> > is not called. When Pm wrote about how to use UpdatePage he did  not
> > mention Lock. But it may be an idea to try and add Lock(2); at the
> > beginning of FixHandlePost, and Lock(0); at the end of the function
> > before Redirect, and see what happens? Just guessing, as I have no
> > clue.
> 
> My method is always to isolate the problem, then start hacking :-) 
> Hopefully, the issue will be obvious once isolated.

I don't know if this is the issue, but there's at least one big
nasty potential bug in fox.php:  all of the calls to RetrieveAuthPage()
are passing READPAGE_CURRENT, which means that any page history
is being lost when UpdatePage() is called.  

The READPAGE_CURRENT value says "give me only the most recent 
version of the page without any page history", so then UpdatePage() 
doesn't have the page history available to save along with the page.

Again, I don't know if that's related to the current issue, but
it's at least something to be looked at.

Pm




More information about the pmwiki-users mailing list