UpdraftPlus Home › Forums › Paid support forum – UpdraftPlus backup plugin › Migration Failure: PHP Fatal Error
- This topic has 6 replies, 5 voices, and was last updated 12 months ago by Bryle Crodua.
-
AuthorPosts
-
November 8, 2023 at 12:06 am #1947288Justin HarveyParticipant
Hey gang, attempting the migrate to a new domain and it’s failing on the “Database” stage. “A PHP fatal error (Error) has occurred: Call to undefined function mysql_query()”
– Migrating Updraft Plus Version: 2.23.11.1
– Using backsups made from Updraft Version: 1.23.11
– Both installs are WordPress 6.4November 8, 2023 at 12:06 am #1947289Justin HarveyParticipantThis reply has been marked as moderator-only.November 8, 2023 at 10:13 am #1947645jimi gecelterParticipantThis reply has been marked as private.November 8, 2023 at 10:17 am #1947648nicogeissParticipantI second this. Interestingly, UpdraftPlus was functioning properly on WordPress 6.3.2, but we’ve encountered the same issue after upgrading some of our websites to WordPress 6.4.
It seems that UpdraftPlus is calling the deprecated mysql_query() function, which no longer works with the new WordPress 6.4 release, as confirmed by the official PHP documentation stating, ‘this extension was deprecated in PHP 5.5.0, and it was removed in PHP 7.0.0. Instead, the MySQLi or PDO_MySQL extension should be used.’ Source: https://www.php.net/manual/en/function.mysql-query.php.
This suggests that UpdraftPlus should have ideally transitioned to MySQLi or PDO_MySQL long ago. I’m hoping for a quick release of a patch, as migrating or restoring websites on WordPress 6.4 is currently impossible. Is anyone aware of a workaround, or do we know when a patch might be available?
Updraft Plus Version: 2.23.11.26
WordPress Version: 6.4- This reply was modified 12 months ago by nicogeiss.
November 8, 2023 at 10:28 am #1947655jimi gecelterParticipantA temp workaround until the dev team releases a fix or a flag for wp-config.php:
* go into this folder in your wordpress server
wordpress/wp-content/plugins/updraftplus
* editrestorer.php
file.
* on line 4637 change the function to returntrue
always:
`
/**
* Return whether the object is using mysqli or not.
*
* @return Boolean
*/
public function updraftplus_use_mysqli() {
return true;
// return !empty($this->use_mysqli);
}
`
tested and works
November 8, 2023 at 12:17 pm #1947758RichardParticipantHi all,
I can confirm several of my WP 6.4 installations also fail when doing a UpraftPlus restore. Same error as mentioned here.
And thank you Jimi for the quick fix solution, I also found rolling back to WP 6.3 works but neither should have been needed if Updraft team had tested on a newer versions which it seems they don’t.Have opened a support ticket as I’m a paying customer too.
Hopefully they’ll push out a fix ASAP.
November 8, 2023 at 1:34 pm #1947846Bryle CroduaModeratorHi @everyone,
We found that there was a bug on our last version. We have released a new version now with the fix. Please update to 2.23.12.x.
Apologies for the inconvenience.
Best Wishes,
Bryle -
AuthorPosts
- The topic ‘Migration Failure: PHP Fatal Error’ is closed to new replies.