Up to 50 percent off

Disable post editing when post is in "publish/live" status?

This topic contains 4 reply and 2 voices, and was last updated by paperweight 10 years, 12 months ago
Viewing 4 Posts - 1 through 4 (of 4 total)
Author Posts
November 16, 2013 at 9:57 pm 10179
paperweight We currently have this option: Disable post editing while post in "pending" status It would be extremely beneficial to also add this function: Disable post editing when post is in "publish/live" status The reason: I want my users to ONLY edit posts if they have not submitted it. After they submit it, it should be in Draft status for the admin to approve it. So when it is submitted and when it is published, User should not have the ability to edit anything anymore. Is this possible to add? Ot is this possible to also have me tweak in the code now? Or, is this already available but I am not doing it correctly? ;)
November 17, 2013 at 11:42 am 10199
Tareq Hasan Tareq Hasan

May be I helped you something like this before, with a different post status?

Anyway, you need to change /class/frontend-dashboard.php in line 178 and add publish status.
[php]if ( ( $post->post_status == ‘pending’ || $post->post_status == ‘publish’ ) && $disable_pending_edit == ‘on’ ) { [/php]

November 19, 2013 at 11:11 pm 10270
paperweight paperweight

Right, however I have a problem with post_status=draft and post_status=pending. They both appear to do the same thing in this WPUF Pro plugin?

For example, when a user makes a Post but wants to save a draft, what post_status is that saved?

Then when that user submits the Post to the Admin but we want to save it in Draft format before it is published by Admin, what post_status is that?

I am trying to show text if the user saved a draft, but then I wan tto show other text when the user submits the Post but the Post is not yet published. So that is my problem, and it seems like pending and draft do the same thing here but they should not. Am I correct or am I looking at this problem incorrectly? 😉

November 20, 2013 at 10:21 am 10291
Tareq Hasan Tareq Hasan

For example, when a user makes a Post but wants to save a draft, what post_status is that saved?

If the user clicks save as draft, it saves as draft. Once he hits the submit button, then it follows the forms post_status setting.

Your problems are complex and I am not sure how to answer them :-/

November 20, 2013 at 11:31 pm 12598
paperweight paperweight

Thanks Tareq. I don’t intend to pose difficult problems. 🙂 We are trying to configure it around our needs. I think we figured this out now. Great plugin and great support~

Viewing 4 Posts - 1 through 4 (of 4 total)