Skip Navigation

[Resolved] Dynamically set posts in draft mode based on Event Date field.

This support ticket is created 3 years, 1 month 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: Africa/Casablanca (GMT+01:00)

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by terryR 3 years ago.

Assisted by: Jamal.

Author
Posts
#2008603
Screenshot 2021-04-02 at 18.32.37.png

Hello, can you please advise me if there is a way to set dynamically a post from a view to go into draft mode automatically after it expires which is related to my Event Date field. Please refer to the screenshot attached.

Currently I have managed the post to not show after its date expires but need to make this post to go in Draft mode as well. Please refer to the screenshot attached.

Thank you.

#2009027

Jamal
Supporter

Languages: English (English ) French (Français )

Timezone: Africa/Casablanca (GMT+01:00)

Hello and thank you for contacting the Toolset support.

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/

I hope this helps. Let me know if you have any questions.

#2010233

My issue is resolved now. Thank you!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.