diff --git a/e107_admin/plugin.php b/e107_admin/plugin.php index 3a5e92b8f..a48dbcda8 100644 --- a/e107_admin/plugin.php +++ b/e107_admin/plugin.php @@ -30,7 +30,7 @@ define("ADMIN_GITSYNC_ICON", e107::getParser()->toGlyph('fa-refresh', array('siz global $user_pref; -if(deftrue('e_DEBUG_PLUGMANAGER')) +if(!deftrue('e_DEBUG_PLUGMANAGER')) { require_once(e_HANDLER.'plugin_class.php'); require_once(e_HANDLER.'file_class.php'); diff --git a/e107_handlers/mysql_class.php b/e107_handlers/mysql_class.php index 3b9eadb62..010bb4bc7 100644 --- a/e107_handlers/mysql_class.php +++ b/e107_handlers/mysql_class.php @@ -193,12 +193,7 @@ class e_db_mysql { list($this->mySQLserver,$this->mySQLport) = explode(':',$mySQLserver,2); } - - if($this->mySQLserver === 'localhost') - { - $this->mySQLserver = '127.0.0.1'; // faster by almost 1 second - } - + try { $this->mySQLaccess = new PDO("mysql:host=".$this->mySQLserver."; port=".$this->mySQLport, $this->mySQLuser, $this->mySQLpassword, array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)); @@ -289,13 +284,7 @@ class e_db_mysql { list($this->mySQLserver,$this->mySQLport) = explode(':',$mySQLserver,2); } - - if($this->mySQLserver === 'localhost') - { - $this->mySQLserver = '127.0.0.1'; // faster by almost 1 second. - } - - + if($this->pdo) // PDO { try @@ -2116,7 +2105,7 @@ class e_db_mysql if ($prefix == '') $prefix = $this->mySQLPrefix; - if (FALSE === ($result = $this->gen('SHOW COLUMNS FROM '.$prefix.$table))) + if (FALSE === ($result = $this->gen('set innodb_stats_on_metadata=0;SHOW COLUMNS FROM '.$prefix.$table))) { return FALSE; // Error return } @@ -2186,7 +2175,7 @@ class e_db_mysql $this->mySQLaccess = $db_ConnectionID; } - $result = $this->gen("SHOW COLUMNS FROM ".$this->mySQLPrefix.$table); + $result = $this->gen("set innodb_stats_on_metadata=0;SHOW COLUMNS FROM ".$this->mySQLPrefix.$table); if ($result && ($this->rowCount() > 0)) { $c=0;