be smart and autodetect root -- it can still be ovverriden if needed -- :)
authorx2000habouzit <x2000habouzit>
Tue, 23 Nov 2004 11:10:41 +0000 (11:10 +0000)
committerx2000habouzit <x2000habouzit>
Tue, 23 Nov 2004 11:10:41 +0000 (11:10 +0000)
include/xorg.globals.inc.php.in
include/xorg.globals/.cvsignore [new file with mode: 0644]
install.d/platal.conf

index 432f4d6..cc0d63b 100644 (file)
@@ -18,7 +18,7 @@
  *  Foundation, Inc.,                                                      *
  *  59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                *
  ***************************************************************************
-    $Id: xorg.globals.inc.php.in,v 1.4 2004-11-22 21:40:47 x2000habouzit Exp $
+    $Id: xorg.globals.inc.php.in,v 1.5 2004-11-23 11:10:41 x2000habouzit Exp $
  ***************************************************************************/
 
 require_once("diogenes.core.globals.inc.php");
@@ -53,16 +53,21 @@ class XorgGlobals extends DiogenesCoreGlobals
 
     /** paths */
     var $baseurl   = "http://localhost/xorg";
-    var $root      = "/usr/share/xorg";
     var $spoolroot = "/var/spool/xorg";
+    var $root      = null;
 
     /** recherche */
     var $public_max_search_results = 25;
     var $search_results_per_page   = 20;
 
     function XorgGlobals() {
-        $ini = dirname(dirname(__FILE__)).'/configs/platal.conf';
-        $array = parse_ini_file($ini, true);
+        $this->root = dirname(dirname(__FILE__));
+
+        foreach(glob($this->root.'/include/xorg.globals/*.inc.php') as $inc) {
+            require_once($inc);
+        }
+        
+        $array = parse_ini_file($this->root.'/configs/platal.conf', true);
         if (!is_array($array)) {
             return;
         }
diff --git a/include/xorg.globals/.cvsignore b/include/xorg.globals/.cvsignore
new file mode 100644 (file)
index 0000000..e69de29
index 5e8f067..d7bc298 100644 (file)
@@ -8,7 +8,6 @@ dbpwd      = "***"
 
 ; base url of the site, WITHOUT LEADING /
 baseurl    = "http://dev.m4x.org/~x2000habouzit";
-root       = "/home/x2000habouzit/dev/public/";
 spoolroot  = "/home/x2000habouzit/dev/public/";
 
 econfiance = "***";