Disabled BP, re-enabled BP, now wp-admin shows slew of MySQL errors!
-
Hi there,
We have a multi-site WordPress 3.0.1 installation with BP 1.2.5.2 installed.
Today I just accidentally clicked “Network Deactivate” for the BuddyPress plugin, when I meant to deactivate a different one. Realizing my mistake, I immediately clicked “Network Activate” again for BuddyPress, and wp-admin came back with a page filled with a slew of these errors:
Warning: mysql_real_escape_string(): 8 is not a valid MySQL-Link resource in /home/wmaster/yexpress.net/wp-includes/wp-db.php on line 785
Warning: mysql_real_escape_string(): 8 is not a valid MySQL-Link resource in /home/wmaster/yexpress.net/wp-includes/wp-db.php on line 785
Warning: mysql_real_escape_string(): 8 is not a valid MySQL-Link resource in /home/wmaster/yexpress.net/wp-includes/wp-db.php on line 785
…BuddyPress looks to be active again, because I can see the admin bar up top, and our home page is looking okay. But WP Admin side was basically unusable because it was just crammed with the above errors.
So in my panic so as not to halt our team’s development I changed the offending function so that PHP warnings would be suppressed:
` function _real_escape( $string ) {
if ( $this->dbh && $this->real_escape ) {
$orig_level = error_reporting();
error_reporting(E_ALL ^ E_WARNING);
$result = mysql_real_escape_string( $string, $this->dbh );
error_reporting($orig_level);
return $result;
}
else
return addslashes( $string );
}`At least now wp-admin is somewhat usable, though there are still a handful of similar MySQL errors still appearing in the header of every wp-admin page request:
Warning: mysql_error(): 8 is not a valid MySQL-Link resource in /home/wmaster/yexpress.net/wp-includes/wp-db.php on line 922
…Another serious problem I noticed is that the “admin” account I’ve been using, which is supposed to be a WPMU Super-Admin, has lost a lot of its rights. For instance, I can’t administer the global users table, or modify the available plugins to activate for sub-sites…
Any help would be so appreciated! I’m a bit panicky because my other developers need to be able to use wp-admin regularly.
Thanks…
- The topic ‘Disabled BP, re-enabled BP, now wp-admin shows slew of MySQL errors!’ is closed to new replies.