implementation sgbd herite de mw_sgbd
[mtweb] / mw / app / init / 0300_data.php
index fd785f7..672de25 100644 (file)
     if(!class_exists($sgbd_impl)){
       $this->erreur("Impossible de trouver la classe d'implementation du sgbd ".$this->bdd("sgbd"), true);
     }
-    $sgbd = new mw_sgbd(
-      new $sgbd_impl(
-        array(
-          "host" => $this->bdd("host"),
-          "base" => $this->bdd("base"),
-          "user" => $this->bdd("user"),
-          "password" => $this->bdd("password")
-        )
-      ),
-      $this
+    $sgbd = new $sgbd_impl(
+      $this,
+      array(
+        "host" => $this->bdd("host"),
+        "base" => $this->bdd("base"),
+        "user" => $this->bdd("user"),
+        "password" => $this->bdd("password")
+      )
     );
     if(!$sgbd->extention_ok()){
       $this->erreur("L'extention php ".$this->bdd("sgbd")." n'est pas installée", true);