Use cron to create a non blocking task

For instance, since the configured cron tasks will only be run on page load, the task might not be run at the desired interval if there are no visitors. To prevent this, you need to use your operating system’s task scheduler. For this, you need to define define(‘DISABLE_WP_CRON’, true); in your wp-config.php file. After that, … Read more

WordPress function, Run using Crontab

define(‘DISABLE_WP_CRON’, true); This line disables the default behaviour of WP Cron. Which is being triggered by a user that visits the site. This is bad for a couple of reasons (nobody might visit, tasks are started via apache handler instead of PHP CLI, …). Now, if you have disabled it, you need another way to … Read more

Wp Cron and WordPress Updates

If I disable wp-cron from config, will automatic updates still work? No, neither will scheduled posts, transient cleanup, trash clearing after 30 days, or automatic plugin updates, and some other things. Anything that relies on timed or scheduled activities will break. It seems you already know the solution, though the real solution is to identify … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)