With my hosting, the WP-Cron is somehow only working sporadically. This also happens more often when pages have very few visitors, as WP Cron is usually triggered when someone makes a page call. Anyway: Sometimes there are cases in which you want to switch off the internal cron job of WordPress in order to then run the wp-cron.php file manually yourself in other ways.
Chapter in this post:
Entry in wp-config.php disables WP-Cron
To completely disable the WordPress cron job, enter the following lines in the wp-config.php file. It doesn't matter where you put them, just try not to break other lines.
For example, you can paste the code after the line: $table_prefix = 'wp_';
Here is the code you insert to turn off the cron job:
/* WP-Cron deaktivieren */
define('DISABLE_WP_CRON', true);
This should prevent the WordPress cron job from being triggered in the future.
Where can I find the wp-config.php file?
Everyone who runs a WordPress website will sooner or later access the file wp-config.php
need access. This file is located in the root of your WordPress installation. To be more precise, it is in the same directory as the folders wp-admin
, wp-content
and wp-includes
can be found.
To access the file, you can use an FTP client such as FileZilla, Cyberduck, or Transmit, or use your web hosting service's file manager. Once you've logged in, simply navigate to your site's root directory and look for the wp-config.php
File.
This file is important as it contains the configuration details of your WordPress installation, including database information and other settings. It is therefore advisable to make a copy of the file before modifying it.
Related Articles
Jens has been running the blog since 2012. He acts as Sir Apfelot for his readers and helps them with technical problems. In his spare time he rides electric unicycles, takes photos (preferably with the iPhone, of course), climbs around in the Hessian mountains or hikes with the family. His articles deal with Apple products, news from the world of drones or solutions to current bugs.