“Could not open input file: wp-cron.php?import_key=” in shell?

Or, you could use WP-CLI which was developed for scenarios like these. After a short installation like this $ curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar $ chmod +x wp-cli.phar $ sudo mv wp-cli.phar /usr/local/bin/wp You can run your scheduled tasks like so $ wp cron event run –due-now –path=/var/www/mywebsite.com/ or via crontab (every 5mins) */5 * * * … Read more

Running WP-Cron on Multisite networks the right way?

After you’ve added the constant in wp-config.php defined(‘DISABLE_WP_CRON’) or define(‘DISABLE_WP_CRON’, true); WP-CLI And assuming you have your config.yml setup correctly, you can ommit the –path flag when calling cron run. wp cron event run –due-now [<hook>…] One or more hooks to run. [–due-now] Run all hooks due right now. [–all] Run all hooks. To run … Read more

CPU Overloading due to some hooks

This code is causing your replace_authors_name_attributes() function to run every time a page is visited on your site, so yes, your hooks are running: schedule_authors_consistency() { if (!wp_next_scheduled(‘consistent_author’)) { wp_schedule_single_event(time(), ‘consistent_author’); } } add_action(‘init’, ‘schedule_authors_consistency’); Since you do this three times and your code queries every product each time this is going to absolutely hammer … Read more

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