I used to have my website on GoDaddy’s Managed WordPress Hosting. I loved it. It was easy to set up and was fairly fast. Especially for shared hosting. I have since moved to a VPS, which is way faster and more reliable.
One of the services I offer to clients is WordPress Care Plans. By helping clients maintain their websites, I take a load off of their shoulders so they don’t have to worry about things going wrong.
Since this is a subscription based product, I use WooCommerce and their Subscriptions add-on. It’s a great solution to keep track of products and clients. However, Managed hosting (not just GoDaddy’s) sometimes has issues with running Cron jobs. WordPress uses Cron jobs for lots of things, such as posting scheduled blog posts.
WooCommerce uses Cron jobs to bill your clients on the period you set. In my case, I am charging monthly fees.
If you’ve reached this tutorial, it’s because you’re probably having problems with WooCommerce trying to bill and collect payments from your customers. Or you are scheduling posts for a future date and they aren’t being posted on time.Is #WooCommerce Subscriptions not billing your customers on Managed WP Hosting? Let's fix it. Click To Tweet
The problem is WP-Cron and the Cache
Caching is great for websites. It speeds them up and provides a better experience for your visitors. However, sometimes it doesn’t play nicely with WP-Cron, the time based job scheduler WordPress uses.
wp-cron.php is unable to do its thang. The Cron jobs aren’t able to run and are just stacking up in the queue.
Let’s Solve This With A Cron Manager
The best solution for this pretty simple. We are going to use a third party Cron job service to manually hit WP-Cron at set intervals. This will make sure the Cron jobs run on time. The best part is, you set it and forget it. If there is an error, you’ll know about it!Schedules Posts not being send out on Managed #WordPress Hosting? It's your cache. Let's fix it. Click To Tweet
Go into your
wp-config.php file and disable wp-cron for trying to service itself by putting
define('DISABLE_WP_CRON', 'true'); into it. Doing this will still allow jobs to be kept in the queue, which we want.
Now, we’ll use an external service to send a GET HTTP request at the fixed automated time we specify. It’s easy, simple, and takes care of our issue right away.
I use setcronjob.com. It’s only $10/yr. You can also use easycron.com; virtually the same thing. They both easily get the job done. All you have to do is choose a time interval, such as 1 Hour. Then enter the URL to Call:
Just make sure to change yourdomainname with your actual domain.
The URL is pointed to the
wp-cron.php file on your server. The parameters are specifying to start the Cron job without your cache.
Lastly, make sure to set the correct Time Zone. Make sure your also set the correct time zone in your WordPress Settings.
Tagged with: wordpress