The scheduling in PublishPress Future is handled by cron jobs.
This plugin does require that WP Cron is setup and functional on your webhost. Some hosts do not support this, so please check and confirm if you run into issues using the plugin.
You can see all the active cron jobs on your site by going to “Future” in your WordPress admin menu and then clicking the “Diagnostics” tab. This table will show all currently scheduled cron events with the connected settings. PublishPress Future creates an event called
postExpiratorExpire. You can see this in the image below:
PublishPress Future will show whether or not a cron job has been successfully set up for your posts to expire. In the image below, “Cron event schedule” means that everything is working correctly.
If the cron job was not created successfully, PublishPress Future will show you the message in the image below: “Cron event not found”.
Technical details for PublishPress Future cron jobs #
If you want to see expiry details in the database, WordPress stores cron jobs in the
_options table. The option_name is
This code below shows a typical cron job entry from PublishPress Future:
Some of the specific details are also held in the
_postmeta table. In the image below, the “expireType” is set to “Delete” so this post will be entirely removed from the site when it expires.
- Post ID: 10
- Expiry Date: September 3, 2021 8:56 pm. This is set using Unix time which is an integer number that counts date and time in seconds since 1970-01-01. There are convertors available for Unix time including Epoch Converter.
_wp_old_date in the image above is a useful WordPress core feature that is explained in this article.
Alternatives to WP Cron #
In some situations, using the normal WP Cron option in the WordPress core is not an option, or you prefer to use an off-site cron task.
First, define a constant in the site's
Next, configure a cron job. But this can be done on different ways, depending on the server. The cron job should call this:
wget -q -O - https://mydomain.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1