<div class="gmail_quote">On Tue, Jun 16, 2009 at 4:29 PM, adam overton <span dir="ltr">&lt;<a href="mailto:a@plus1plus1plus.org" target="_blank">a@plus1plus1plus.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

<div><div><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div>

...</div></span></span></span></span></span></div></div></blockquote><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Verdana; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div>

the workaround that i thought could work but currently gives me errors goes something like this - instead of having fox/foxedit redirect=1 (i.e. to the same page), have it redirect to the same page with ?action=updatePage where the appropriate functions are called. here&#39;s my code in config.php:</div>

<div><br></div><div><div>if ($action==&quot;updatePage&quot;) {</div><div><span style="white-space: pre;">        </span>$thispage = ReadPage($pagename);</div><div><br></div><div><span style="white-space: pre;">        </span>//WritePage($pagename, $thispage);</div>

<div><span style="white-space: pre;">        </span>UpdatePage($pagename, $thispage, $thispage);</div><div><span style="white-space: pre;"></span></div></div></span></span></span></span></span></div></div></blockquote><div><br>
I can&#39;t speak to the rest of it, but I know I had a bit of a go-round with UpdatePage() being called in config.php (back in March, but it looks like a lot of the discussion was off-list).  My conclusion was that UpdatePage() requires certain variables to be set before it can be called and those initializations occur after config.php is called.  I &quot;peeled a couple layers&quot; trying to manually do the initializations in config.php before calling UpdatePage() and then determined I needed to pursue an alternate solution...<br>
<br>Quoting from <a href="http://www.pmwiki.org/wiki/PmWiki/Functions">http://www.pmwiki.org/wiki/PmWiki/Functions</a>:<br><br><code>UpdatePage()</code> cannot be called directly from config.php
because there are necessary initializations which occur later in
pmwiki.php. It is not enough to just load stdconfig.php. If you want to
use <code>UpdatePage()</code> you will need to do it within a custom markup, a custom markup expression, or a custom action.<br><br>-Peter <br></div></div>