Most base libraries now loaded from googleapis. Changes to the way LiveGridForms...
[infodrom/rico3] / plugins / php / dbClass3.php
index 14ccc3f..9dce42b 100644 (file)
@@ -855,7 +855,7 @@ class dbClass
 // -------------------------------------------------------------\r
   function dbClass()\r
   {\r
-    $this->Provider="localhost";\r
+    $this->Provider="127.0.0.1";\r
     $this->debug=false;\r
     $this->ConnTimeout=30; // seconds\r
     $this->LockTimeout=5000; // milliseconds\r
@@ -932,9 +932,10 @@ class dbClass
     $this->Dialect="MySQL";\r
     $this->dbDefault = $DefDB;\r
     $this->dbMain = mysql_connect($this->Provider,$userid,$pw);\r
-    mysql_select_db($DefDB,$this->dbMain);\r
     $this->db =& new dbClass_mysql($this->dbMain);\r
-    if ($this->CheckForError("opening connection")) return false;\r
+    if ($this->CheckForError("opening connection to " . $this->Provider)) return false;\r
+    mysql_select_db($DefDB,$this->dbMain);\r
+    if ($this->CheckForError("selecting database " . $DefDB)) return false;\r
     return true;\r
   }\r
 \r