<?php
- if(($plugins = $this->plugins("DESC")) === false){
- $this->erreur("Impossible de lire les plugins pour charger les modules de donnees", true);
- }
- $data = new mw_data(true);
+ // -------------------------------------------------------------------------
+ // sgbd
+ //
+
+ $sgbd_impl_file = $this->path("mw_dir")."env/sgbd/mw_".$this->bdd("sgbd").".php";
if($this->bdd("sgbd")){
- if(!$this->app_file_exists("data/impl/mw_".$this->bdd("sgbd").".php")){
+ if(!file_exists($sgbd_impl_file)){
$this->erreur("Impossible de trouver le fichier d'implementation du sgbd ".$this->bdd("sgbd"), true);
}
$sgbd_impl = "mw_".$this->bdd("sgbd");
- if(!class_exists($sgbd_impl)) require_once $this->app_file("data/impl/".$sgbd_impl.".php");
+ if(!class_exists($sgbd_impl)) require_once $sgbd_impl_file;
if(!class_exists($sgbd_impl)){
$this->erreur("Impossible de trouver la classe d'implementation du sgbd ".$this->bdd("sgbd"), true);
}
$this->erreur("L'extention php ".$this->bdd("sgbd")." n'est pas installée", true);
}
}
+
+ // -------------------------------------------------------------------------
+ // data
+ //
+
+ if(($plugins = $this->plugins("DESC")) === false){
+ $this->erreur("Impossible de lire les plugins pour charger les modules de donnees", true);
+ }
+ $data = new mw_data(true);
foreach($plugins as $plugin_name => $plugin){
if($plugin["installed"] && $plugin["enabled"]){
$data->load_modules($this->path("mw_dir")."plugins/".$plugin_name."/app/", "data/modules/share/");