Please Note: This wiki is valid for v2.9.x and below of the LiteSpeed Cache Plugin for WordPress. If you are using v3.0 or above, please see the new documentation.

Scheduled Posts are published in WordPress through a WP cron job. Normally, WordPress triggers the cron job each time a request hits the backend. The backend is rarely hit, however, when using a cache, which causes scheduled posts to publish late.

LSCWP will correctly purge the cache when a scheduled post is published in the cron job. All you need to do is make sure that you can reliably hit the backend. This can be done by scheduling a cron job to hit wp-cron.php at your ideal interval.

For Example, to update scheduled posts every 15 minutes:

*/15 * * * * wget http://your_wp_site/wp-cron.php

When using a server level cron job, WordPress suggests defining DISABLE_WP_CRON in your wp-config file to disable checking wp-cron on a backend hit.

define('DISABLE_WP_CRON', true);

This may be useful in reducing the number of calls made to wp-cron if that is desired.

For a more in-depth discussion of this issue, see our blog.

  • Admin
  • Last modified: 2020/05/04 13:55
  • by Shivam Saluja