Introduction
WordPress's wp-cron is not a real cron job. A cron job runs at a specified time or interval, while wp-cron runs when the page is loaded. This can cause low-traffic sites to miss scheduled posts. Creating a cronjob to run wp-cron will ensure that scheduled posts are not missed regardless of site traffic.
Procedure
- Open the site's wp-config.php file in a text editor.
- Add the following line after the
<?php
line.define('DISABLE_WP_CRON', true);
- Save the changes and close the text editor.
- Log into the user's cPanel account.
- Open the "Cron Jobs" application in the "Advanced" section of cPanel.
- Create a new cron job that runs the following command every 15 minutes.
wget -q -O - http://domain.tld/wp-cron.php?doing_wp_cron >/dev/null 2>&1
Please note that "domain.tld" must be replaced with the site's domain name.
Additional resources
How to edit files via File Manager
How to edit a file on command-line
How to create or edit cron jobs in the cPanel user interface