[pmwiki-devel] read, edit and save a page
Patrick R. Michaud
pmichaud at pobox.com
Tue Nov 14 14:45:44 CST 2006
On Tue, Nov 14, 2006 at 06:18:32PM -0200, Guillermo Calderon - INCO wrote:
> I want to write php code to do the following:
>
> 1) read a page (by name) and store it in a variable (say $text)
> 2) modify $text (I known how to do this)
> 3) save the page with $text as the new content
$page = ReadPage($name)
$text = $page['text'];
# ...
$text = modify($text); # you do this part
# ...
$newpage = $page;
$newpage['text'] = $text;
UpdatePage($name, $page, $newpage);
Pm
More information about the pmwiki-devel
mailing list