X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/098a79f0819ebb89b7d48df4a6b154af4560f68e..7706d5a5ca4aa6f4f093beadbf688d2cccaa4bef:/dbinstall.php?ds=inline
diff --git a/dbinstall.php b/dbinstall.php
old mode 100644
new mode 100755
index c65358a8..b755a8bd
--- a/dbinstall.php
+++ b/dbinstall.php
@@ -28,55 +28,167 @@
require_once('WEB-INF/config.php');
require_once('WEB-INF/lib/common.lib.php');
-if (!require_once('MDB2.php')) {
- die ("Unable to require MDB2 module. Please check it
\n");
-}
require_once('initialize.php');
import('ttUserHelper');
import('ttTaskHelper');
+// setChange - executes an sql statement. TODO: rename this function to something better.
+// Better yet, redo the entire thing and make an installer.
function setChange($sql) {
- print "
".$sql.""; - $mdb2 = getConnection(); - $affected = $mdb2->exec($sql); - if (is_a($affected, 'PEAR_Error')) { - print "error: ".$affected->getMessage()."
".$sql.""; + $mdb2 = getConnection(); + $affected = $mdb2->exec($sql); + if (is_a($affected, 'PEAR_Error')) + print "error: ".$affected->getMessage()."