forked from extern/egroupware
applied patch from mdean to make the setup pgsql friendly
This commit is contained in:
parent
636b37b3e9
commit
97900295c9
@ -36,26 +36,18 @@
|
|||||||
}else{ /* authentication settled. Moving to the database portion. */
|
}else{ /* authentication settled. Moving to the database portion. */
|
||||||
loaddb();
|
loaddb();
|
||||||
$db->Halt_On_Error = "no";
|
$db->Halt_On_Error = "no";
|
||||||
|
|
||||||
// Skeeter
|
$tables = $db->table_names();
|
||||||
// This is a patch sent in by mdean
|
if (is_array($tables) && count($tables()) > 0){
|
||||||
// Disable both of these lines and replaced with the 2 llines following
|
|
||||||
// $db->query("show tables");
|
|
||||||
// if ($db->num_rows()){
|
|
||||||
$tables = $db->table_names();
|
|
||||||
if (is_array($tables) && count($tables) > 0) {
|
|
||||||
/* tables exists. checking for post beta version */
|
/* tables exists. checking for post beta version */
|
||||||
$db->free();
|
|
||||||
$db->query("select app_version from applications where app_name='admin'");
|
$db->query("select app_version from applications where app_name='admin'");
|
||||||
$db->next_record();
|
$db->next_record();
|
||||||
$oldversion = $db->f("app_version");
|
$oldversion = $db->f("app_version");
|
||||||
$db->free();
|
|
||||||
if (isset($oldversion)){
|
if (isset($oldversion)){
|
||||||
if ($oldversion == $phpgw_info["server"]["version"]){
|
if ($oldversion == $phpgw_info["server"]["version"]){
|
||||||
$db->query("select config_value from config where config_name='freshinstall'");
|
$db->query("select config_value from config where config_name='freshinstall'");
|
||||||
$db->next_record();
|
$db->next_record();
|
||||||
$configed = $db->f("config_value");
|
$configed = $db->f("config_value");
|
||||||
$db->free();
|
|
||||||
if ($configed){
|
if ($configed){
|
||||||
$stage = 3.1;
|
$stage = 3.1;
|
||||||
$header_msg = "Stage 3 (Needs Configuration)";
|
$header_msg = "Stage 3 (Needs Configuration)";
|
||||||
@ -75,11 +67,9 @@
|
|||||||
/* no tables, so checking if we can create them */
|
/* no tables, so checking if we can create them */
|
||||||
|
|
||||||
/* I cannot get either to work properly
|
/* I cannot get either to work properly
|
||||||
$db->free();
|
|
||||||
$isdb = $db->connect("kljkjh", "localhost", "phpgroupware", "phpgr0upwar3");
|
$isdb = $db->connect("kljkjh", "localhost", "phpgroupware", "phpgr0upwar3");
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$db->free();
|
|
||||||
$db_rights = $db->query("CREATE TABLE phpgw_testrights ( testfield varchar(5) NOT NULL )");
|
$db_rights = $db->query("CREATE TABLE phpgw_testrights ( testfield varchar(5) NOT NULL )");
|
||||||
|
|
||||||
if (isset($db_rights)){
|
if (isset($db_rights)){
|
||||||
|
Loading…
Reference in New Issue
Block a user