wp-load.php file is getting empty

Viewed 1755

I have multiple WordPress websites. All of them have been running fine for a long time. But suddenly my WP websites shown the error:

This page isn’t working

When I investigate the problem I found this in the error log:

"Uncaught Error: Call to undefined function wp() in /home/nc136xrqx05i/public_html/wp-blog-header.php:16"
and the wp-load.php file is 0.

Then I rename the plugin files. Then the websites run but if I try to install a plugin from the plugin folder from dashbaord, wp-load file is becoming empty again and the site goes down.

How can I solve that?

3 Answers

The solution to this issue is to set the permission of the wp-load file to 444 after copying the contents back into the file, but you have to do it quickly because whatever is emptying the file is doing it very fast. I had the very same issue today and tech support for both web host that I am with di

I had the same issue with my site and now I changed the wp-load.php file's permission from 644 to 444 as shown in the image below.

File Manager File's Permission

Also, I suggest you to take regular backup and replace the core files of Wordpress.

I had this problem, and found malicious files located in my wp-content folder (which were thus not overwritten during the re-upload of the WP core files. ) I removed these files - as they were responsible for emptying the wp-load file and the problem was solved :)

Related