[pmwiki-users] EnableDrafts and PmForm

Criss Ittermann crisses at kinhost.org
Wed Oct 22 14:55:37 CDT 2014


I think you have it right.

Member data is edited from their profile page, but not all data they edit is stored on their profile page.  We want to make sure that only admins can "publish" the data to be live, so the data needs to be stored in a -Draft page and I'll make sure the site has a notice for admins when there are draft pages that need approval.

I'll try it and get back on whether it works, thank you.


Crisses

On Oct 22, 2014, at 12:09 PM, Petko Yotov <5ko at 5ko.fr> wrote:

> The current implementation could be changed to require Publish permissions when Drafts are enabled but it would require a password for the data page _before_ trying to save the draft version:
> 
>  if ($_REQUEST['action'] == 'pmform')
>    $HandleAuth['edit'] = 'publish';
> 
> Instead, try adding a hidden field inside your pmform template, something like:
> 
>  (:input hidden postdraft 1:)
> 
> This should cause the post to be considered as if the user had pressed the "Save draft" button while editing the page, so the Draft page will be filled. (Unless I don't quite understand what you're trying to do.)
> 
> Petko
> 
> On 22.10.2014 12:24, Criss Ittermann wrote:
>> When a PmForm writes to another page, it doesn't respect the
>> $EnableDrafts and $EnablePublishAttr features.
>> Is there a way to require a PmForm respect these settings?
>> We have 2 levels of author: admins & members. When a member uses a
>> PmForm to change their profile, it should be approved by an admin
>> before going public. I'm using the drafts system but member data is
>> being stored in a "secret data area".
> 
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20141022/129bc6c5/attachment.html>


More information about the pmwiki-users mailing list