Skip Navigation

[Resolved] Change an event (post) status to draft

This thread is resolved. Here is a description of the problem and solution.

Problem:

How to Automatically change the status of events to draft when his date ends.

Solution:

If you are using Toolset Forms to create the custom post type items there is a native way to achieve this:

Relevant Documentation:

https://toolset.com/course-lesson/setting-up-automatic-post-expiration/

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.

This topic contains 3 replies, has 2 voices.

Last updated by Farhad 2 years, 2 months ago.

Assisted by: Christopher Amirian.

Author
Posts
#2618669

Hi
Tell us what you are trying to do?
Automatically change the status of events to draft when his date ends

Thanksas

#2618721

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

If you are creating these posts using Toolset Forms, there is a built-in expiration feature, check this article https://toolset.com/course-lesson/setting-up-automatic-post-expiration/

But, if you are creating the post from the backend or using other means(another plugin's form), you will need a 3rd party plugin or some custom code(using Cron) to change these posts' statuses. Check the following pages:
- https://wordpress.stackexchange.com/questions/97031/code-to-auto-expire-posts-after-30-days
- hidden link
- https://wordpress.org/plugins/post-expirator/
- https://wordpress.org/plugins/tags/schedule/

Thanks.

#2618723
Screen Shot 2023-06-25 at 14.02.05.png

Hi
When I check the toolset screen there is no "Forms" tab, as the video you sent showed..
Attached screenshot

Thanks

#2618737

My issue is resolved now. Thank you!