wordpress: Fatal error: Call to undefined function

2019-09-08 07:14发布

问题:

I had my blog on live server it worked fine with my old site, I made backup of that blog folder and after upload new site I also upload that blog folder with out any change in any file but if I try to access my blog page browser shows that:

Fatal error: Call to undefined function is_wp_error() in /home/content/i/m/r/imranskh/html/blog/wp-includes/load.php on line 339

I googled but no clear solution found.

回答1:

It would be helpful to know the site address and the version of WP you're running and what host your using, but your problem is with the MySQL database (and what language the site is in)

Line 339 of load.php is an error check for the MySQL database table prefix.

You said you moved the "files" but how did you migrate the MySQL database between sites?

Go look in your wpconfig.php and see what the table prefix is set to (find the line starting: $table_prefix = 'something here' )

See that that 'something here' prefix matches your actual MySQL database prefix (check that with a PHPMyAdmin or a SQL client).

Some shared hosts will change this table prefix automatically be unique if you use a simple script installer for WordPress. Did you use an installer to setup WordPress and your MySQL database, or did you do it manually?



回答2:

Reinstall WP and then insert wp_posts (old table backup) into new new table.



标签: php wordpress