[pmwiki-users] Is 'Page Creator' worth to discuss?
Patrick R. Michaud
pmichaud at pobox.com
Sun Feb 24 09:55:48 CST 2008
On Sun, Feb 24, 2008 at 03:29:30PM +0000, Hans wrote:
> Sunday, February 24, 2008, 2:30:06 PM, Patrick R. Michaud wrote:
>
> > To add an attribute for 'cauthor':
>
> > $PageAttributes['cauthor'] = '$[Page created by:]';
>
> thanks!
>
> And is there a mechanism with which to populate this with
> some default value, perhaps taken from $Author, when a new page
> gets saved fist time?
## not tested, but gives the general idea
function SetPageCreator($pagename, &$page, &$new) {
global $EnablePost, $Author;
if ($EnablePost) SDV($new['cauthor'], $Author);
}
unshift($EditFunctions, 'SetPageCreator');
Pm
More information about the pmwiki-users
mailing list