added configuration portion of the setup

This commit is contained in:
seek3r 2000-12-01 20:07:23 +00:00
parent f5045f8e13
commit 31bb096266
4 changed files with 52 additions and 27 deletions

View File

@ -22,9 +22,6 @@
exit;
}
loaddb();
if ($newsettings["auth_type"] != "ldap") {
setup_header();
}
if ($submit) {
@$db->query("delete from config");
@ -46,10 +43,16 @@
Header("Location: ldap.php");
exit;
} else {
echo "<center>Your config has been updated<br><a href='".$newsettings["webserver_url"]."/login.php'>Click here to login</a>";
//echo "<center>Your config has been updated<br><a href='".$newsettings["webserver_url"]."/login.php'>Click here to login</a>";
Header("Location: index.php");
exit;
}
}
if ($newsettings["auth_type"] != "ldap") {
show_header("Configuration");
}
@$db->query("select * from config");
while (@$db->next_record()) {
$current_config[$db->f("config_name")] = $db->f("config_value");

View File

@ -237,20 +237,32 @@
echo "<br><input type=\"submit\" value=\"Re-Check My Installation\">\n";
echo '</form>';
echo '</td></tr>';
}elseif ($stage == 2.6) {
}elseif ($stage >= 2.6) {
echo '<tr><td align="center">X</td><td>Your tables are current.';
echo "<form method=\"POST\" action=\"tables.php\">\n";
echo "<input type=\"hidden\" name=\"oldversion\" value=\"new\">\n";
echo "<br>Insanity: <input type=\"submit\" name=\"action\" value=\"Delete all my tables and data\">, then re-create the tables.\n";
echo "<br>Insanity: <input type=\"submit\" name=\"action\" value=\"Delete all my tables and data\">\n";
echo '</form>';
echo '</td></tr>';
}
echo ' <tr><td align="left" bgcolor="486591"><font color="fefefe">Step 3 - language management</td><td align="right" bgcolor="486591">&nbsp;</td></tr>';
echo ' <tr><td align="left" bgcolor="486591"><font color="fefefe">Step 3 - Configuration</td><td align="right" bgcolor="486591">&nbsp;</td></tr>';
if ($stage < 3.1) {
echo '<tr><td align="center">O</td><td>Not ready for this stage yet.</td></tr>';
}elseif ($stage == 3.1) {
echo '<tr><td align="center">O</td><td>stage 3.1.<br></td></tr>';
echo '<tr><td align="center">O</td><td>Please phpGroupWare for your environment.';
echo "<form method=\"POST\" action=\"config.php\"><input type=\"submit\" value=\"Configure Now\"></form>";
echo '</td></tr>';
}elseif ($stage == 3.2) {
echo '<tr><td align="center">X</td><td>Configuration completed.';
echo "<form method=\"POST\" action=\"config.php\"><input type=\"submit\" value=\"Edit Current Configuration\"></form>";
echo '</td></tr>';
}
echo ' <tr><td align="left" bgcolor="486591"><font color="fefefe">Step 4 - language management</td><td align="right" bgcolor="486591">&nbsp;</td></tr>';
if ($stage < 4.1) {
echo '<tr><td align="center">O</td><td>Not ready for this stage yet.</td></tr>';
}elseif ($stage == 4.1) {
echo '<tr><td align="center">O</td><td>stage 3.1.<br></td></tr>';
}elseif ($stage == 4.2) {
echo '<tr><td align="center">O</td><td>stage 3.2.<br></td></tr>';
}
echo '</table>';

View File

@ -47,8 +47,17 @@
$db->free();
if (isset($oldversion)){
if ($oldversion == $phpgw_info["server"]["version"]){
$stage = 2.6;
$header_msg = "Stage 2 (Tables are Current)";
$db->query("select config_value from config where config_name='freshinstall'");
$db->next_record();
$configed = $db->f("config_value");
$db->free();
if ($configed){
$stage = 3.1;
$header_msg = "Stage 3 (Needs Configuration)";
}else{
$stage = 3.2;
$header_msg = "Stage 3 (Configuration OK)";
}
}else{
$stage = 2.4;
$header_msg = "Stage 2 (Tables need upgrading)";

View File

@ -47,6 +47,7 @@
$db->query("insert into config (config_name, config_value) values ('httpproxy_port', '')");
$db->query("insert into config (config_name, config_value) values ('showpoweredbyon', 'bottom')");
$db->query("insert into config (config_name, config_value) values ('checkfornewversion', 'False')");
$db->query("insert into config (config_name, config_value) values ('freshinstall', 'True')");
}
if ($useglobalconfigsettings == "on"){