Skip Navigation

[Resolved] Keeping original Post Form author/user after post if approved

This support ticket is created 2 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 1 reply, has 2 voices.

Last updated by Luo Yang 2 years, 2 months ago.

Assisted by: Luo Yang.

Author
Posts
#2485497

Original request for help was closed with no answer: https://toolset.com/forums/topic/keeping-original-post-form-author-user-after-post-if-approved/#post-2484925
I am reposting again.

Tell us what you are trying to do?
I am building a paid directory portion of my site where a business would pay to showcase their business ad on a monthly subscription basis using Toolset Post Forms and WooCommerce Subscriptions. The business owner completes a Toolset Post Form that captures the relevant business contact information and featured images I want to have displayed in their ad and purchases the corresponding subscription product. The Post Form sets the post status to 'Pending Review' after the initial payment is complete so I can check their content and assign which page to display it on before publishing.

In testing this, I was able to complete a purchase with the WooSubscriptions and the post was created and set to Pending Review. However, when I tried to walk through the steps of reviewing the post and then publishing it, the CRED Post Form got attributed to me (the admin) rather than the original post 'author' (the advertiser). I do have the setting of 'After payment completes, make the client the author of the post' on the form, but I can't find where to make the business owner the author of the post after I review it.

A few notes:
-- The Custom Post Type is called 'Premium Advertiser', it is managed by Access with Premium Advertisers able to Publish, Delete own, Edit own, Read

-- I created a custom role of 'Premium Advertiser' and it appears the only permission they have is 'level_0' under the 'Other capabilities' permissions.

-- Maybe I have this messed up and need to allow them more permissions, but I do not want to allow them to access any portion of the dashboard area and see others posts, access to media, etc.

This is preventing me from showing the business owner a list of their own posts on the My Account page because they are no longer the author. Can you assist?

Is there any documentation that you are following?
https://toolset.com/course/wordpress-membership-sites/
https://toolset.com/course/wordpress-directory-and-classifieds-sites/

Is there a similar example that we can see?

What is the link to your site?
form not publicly available yet.

#2486135

Hello,

I have tried it in a fresh WP installation + the latest version of Toolset plugins + Woocommerce plugin, it works fine, see below test site.

Admin login URL:
hidden link

Custom user:
Username: test 1
Password: 111111
hidden link

Here are detail steps:
1) Login as user "test 1"
2) Go to URL:
hidden link
Fill and submit the post form, complete the payment(0 price)

3) Login as admin user
4) Dashboard-> Woocomerce-> Orders, review the order, change the order status to "Complete", save
5) Check the new custom post:
hidden link

I can see the post author is correct: test 1

You might need to ask user to login into your website first, then let him to fill and submit the post form.