[SOLVED] “Disable register_shutdown_function” Error

Andrei Iordache

Andrei Iordache

WordPress Developer

🚀 I Help People Get Found Online | WordPress Development, Core Web Vitals, Security&Maintenance

Introduction

Today, one of my clients messaged me:

“Hello Andrei! I just started a test OpenAI project on the site you have built last year for me, using the wordpress automatic plugin, and I can’t get rid of this error:

If this error persists, please visit the plugin settings page and enable the option named “Disable register_shutdown_function”. This could be a solution.

Can you help me?”

Martin

(And it was a nice 35” conversation after I replied him back). On short, I solved Martin’s site error, and in this post I will teach you how to solve it, too.

How to solve “Disable register_shutdown_function”?

There are many contributing factors for any WordPress error. In this case, the plugin Martin mentioned above, WordPress Automatic, was generated this type of error. Not the plugin itself (good plugin, by the way – of course, used in good faith), but the wrong settings configured by Martin. And because we are not looking for culprits, but for solutions, I found the way how to solve this issue. I will post it below. Before that, I will post some general fixes for this type of WordPress error, which may work.

Don’t forget: Before doing anything, backup your WordPress site! Ty

A short intro about the issue itself

“Disable register_shutdown_function” may indicate you have configured the PHP Execution Time with a low value number (30 is the default WordPress value for the PHP Exec time). In the case of complex plugins (like the one mentioned above), if the execution time expire before the action is completed, the action will not be registered into the database and it will generate this kind of error. That’s said, you have to increase the PHP Execution Time.

How to increase the PHP Execution Time?

There are a few ways to increase the PHP Execution Time. No one is safe for your site if you don’t have any WordPress experience. And even if you have, I strongly recommend you to backup your site.

To increase the PHP execution time in WordPress, you can follow these steps:

1. Edit the .htaccess file located in the root directory of your WordPress installation. Add the following line of code to increase the execution time to 300 seconds:

php_value max_execution_time 300

2. Create a new PHP file called php.ini and add the following line of code to increase the execution time to 300 seconds:

max_execution_time = 300

3. Add the following code to the wp-config.php file located in the root directory of your WordPress installation:

set_time_limit(300);

4. My favourite old one: Go to cPanel > search for Select PHP version (or PHP selector) > search for the field “max_execution_time” and set the value to your standards ( let’s say 7000). 

Solution for WordPress Automatic Plugin


Again, there may be a lot of misconfigurations by the user because, as we know, the devil is hides in the details.

With the last plugin updates, the developers brings 2 new features: OpenAI content creator and PixaBay fetcher, to auto-post related pictures for the new posts. Assuming the plugin worked before you tried to use the last 2 features, I will post the fixes only for the 2 new features:

#1. For OpenAI feature (that’s why Martin picked the plugin).

  • Do you also have an OpenAI account? If not, go an create one. You may get $18 free credits, to spend them in the “playground”.
  • If you already have an OpenAI, have you copied the API key, and inserted it in the right place, in the “Settings” section of WP Automatic? If not, you know what you have to do.

#2. For PixaBay feature

What I wrote above, in the OpenAI’s case +

  • In the Image Options section > Set a featured image from PixaBay for a specific keyword, make sure you insert just 1 related keyword. For example, if you have a budgie pet shop, you have to insert only this word: “budgie”, and not “budgie, green budgie, happy budgie” and so on, because PixaBay will mess with the searches while trying to find images for each and every keyword from the list. So, yes: just 1 keyword.
  • Uncheck the “Find the keywords from the post title and call PixaBay every time to get an image”, because of the same reason as the one above: **[Not recommended] This option may return irelevant images because PixaBay expects a single word so if your title contains “pick a car”, the plugin will search for “pick” which may return an image of flower picking

Lastly, the API may simply not working at the moment you get the error, so you may check it up later.

Conclusion


That’s said, once you configured your campaign, everything should working fine right now. I hope this How to get rid of “If this error persists, please visit the plugin settings page and enable the option named “Disable register_shutdown_function”.” was the solution for your issue.

Happy to help, as usual.

Submit Your Guest Post

Previous Post
Useful WordPress Plugins for Enhancing User Experience
Next Post
Top 6 ChatGPT Plugins in 2023
Lusi StudiosLusi Studios
15:32 22 Jun 22
Andrei did an amazing job! He helped in a very rushed time and he excelled at everything. Thanks again!
I am grateful and I would to thank Websites Seller for their support in site recovery and site transfer. Websites Seller just saved my business. Thank you!
Wouter GhysensWouter Ghysens
11:52 10 Sep 21
Looking for a Wordpress transfer from site A to site B, I found back Andrei from Wesites Seller on Google.He was very proactive in his approach, came with hundreds of ideas and lifetime experiences from other migrations. He knows the wordpress, the hosting and php database as the back of his pocket.And we worked out this migration very smooth. Together we solved it, and myself and my business are very pleased with his approach.100% recommendation & kudo's from out of Belgium!
Ioachim CiobanuIoachim Ciobanu
18:39 14 Jul 21
Websites Seller built my resume site. Deliverables were quickly completed, and I was asked for my feedback at each stage of development. All feedback I gave was implemented in a short time.Another great thing is that he comes with smart solutions, regarding stuff which I didn't initially think of (site security, Google site speed optimization and so on). Basically, he was great, staying in touch, keeping me updated and paid attention to what was most important for my site.Overall, I am very happy with the work done. I highly recommend this developer!
K CollinsK Collins
09:11 19 May 21
I needed help with website speed - to improve my core web vitals - without compromising the usability of my site. Andrei was extremely responsive, proactive and fast. And more importantly, he increased by website speed. Highly recommend him, and I will be using him going forward on all my projects.
js_loader

Submit Your Guest Post

Services

WordPress Website Maintenance Services

WordPress Maintenance Services

WordPress website maintenance service that provides cloud backups, emergency support, weekly website updates, speed and many more.

sally

WordPress Migration Service

Safely transfer your WordPress website to a new location for $75. … Migrate your website to its new host.

lawyer-office

Lawyer Web Design

We specializes in website design, Internet marketing and SEO for lawyers and attorneys throughout the Europe and US.