Title: PHP 5.5 incompatibility
Last modified: August 21, 2016

---

# PHP 5.5 incompatibility

 *  Resolved [techsurgeons](https://wordpress.org/support/users/techsurgeons/)
 * (@techsurgeons)
 * [12 years, 1 month ago](https://wordpress.org/support/topic/php-55-incompatibility/)
 * We’ve updated our server to PHP 5.5 and S&R stopped working
 * Doing a quick scan through the logs, I see entries like this:
 * HP message: PHP Warning: mysql_real_escape_string(): A link to the server could
   not be established in /home/www/X/htdocs/wp-content/plugins/search-and-replace/
   search-and-replace.php on line 514, referer: [http://X.com/wp-admin/tools.php?page=search-and-replace/search-and-replace.php](http://X.com/wp-admin/tools.php?page=search-and-replace/search-and-replace.php)
 * Looking through the code, it seems the now deprecated MySQL extension is being
   used by mysql_fetch_assoc() and others.
 * See: [http://www.php.net/manual/en/function.mysql-fetch-assoc.php](http://www.php.net/manual/en/function.mysql-fetch-assoc.php)
 * Warning
 * This extension is deprecated as of PHP 5.5.0, and will be removed in the future.
   Instead, the MySQLi or PDO_MySQL extension should be used. See also MySQL: choosing
   an API guide and related FAQ for more information. Alternatives to this function
   include:
 *  mysqli_fetch_assoc()
    PDOStatement::fetch(PDO::FETCH_ASSOC)
 * [https://wordpress.org/plugins/search-and-replace/](https://wordpress.org/plugins/search-and-replace/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  [RonG](https://wordpress.org/support/users/rong/)
 * (@rong)
 * [11 years, 11 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863207)
 * Try this version and let me know if it works for you: [http://vnetworx.net/search-and-replace-test-version.zip](http://vnetworx.net/search-and-replace-test-version.zip)
 * You need to put the file into your existing search-and-replace plugin folder.
 *  [Pete](https://wordpress.org/support/users/angio/)
 * (@angio)
 * [11 years, 11 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863213)
 * [@rong](https://wordpress.org/support/users/rong/)
 * I was getting the errors below in the WordPress debug.log. I see your new code
   doesn’t use **mysql_query**. The updated file you linked to is working
 * [09-Jul-2014 19:26:29 UTC] PHP Warning: mysql_query(): Access denied for user‘
   www-data’@’localhost’ (using password: NO) in /var/www/html/wp-content/plugins/
   search-and-replace/search-and-replace.php on line 484
 * [09-Jul-2014 19:26:29 UTC] PHP Warning: mysql_query(): A link to the server could
   not be established in /var/www/html/wp-content/plugins/search-and-replace/search-
   and-replace.php on line 484
 * I’m on WordPress 3.9.1
 * PHP Version 5.5.9-1ubuntu4.2
 * When will you push an update to WordPress.org?
 *  [RonG](https://wordpress.org/support/users/rong/)
 * (@rong)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863218)
 * Soon, I hope. I have to make a few changes in the translations, contact the present
   maintainer, and I really don’t know how the developer uploading stuff works.
 *  [RonG](https://wordpress.org/support/users/rong/)
 * (@rong)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863219)
 * Ok, the plugin author (Frank) will be away for a month, so I tried to fork the
   plugin, but there’s 116 plugins waiting review.
 * You can [download the new plugin directly from my site](http://vnetworx.net/search-and-replace-continued.zip)
   for now.
 *  Plugin Contributor [Frank Bueltge](https://wordpress.org/support/users/bueltge/)
 * (@bueltge)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863225)
 * The fixes from RonG are now inside the new version. THANKS to RonG

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘PHP 5.5 incompatibility’ is closed to new replies.

 * ![](https://ps.w.org/search-and-replace/assets/icon-256x256.png?rev=1776844)
 * [Search & Replace](https://wordpress.org/plugins/search-and-replace/)
 * [Support Threads](https://wordpress.org/support/plugin/search-and-replace/)
 * [Active Topics](https://wordpress.org/support/plugin/search-and-replace/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/search-and-replace/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/search-and-replace/reviews/)

## Tags

 * [MySQL](https://wordpress.org/support/topic-tag/mysql/)
 * [PHP5.5](https://wordpress.org/support/topic-tag/php5-5/)

 * 5 replies
 * 4 participants
 * Last reply from: [Frank Bueltge](https://wordpress.org/support/users/bueltge/)
 * Last activity: [11 years, 9 months ago](https://wordpress.org/support/topic/php-55-incompatibility/#post-4863225)
 * Status: resolved