From da97c2fc663627daea6fb82c048579f8b28d9721 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Thu, 19 Jul 2007 22:38:19 +0000 Subject: [PATCH] r1583: - If the version is bad, send them to upgrade16.php in hopes of fixing the problem - Add upgrade16.php --- install/global.php | 3 +- install/upgrade.php | 8 ++++- install/upgrade16.php | 75 +++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 84 insertions(+), 2 deletions(-) create mode 100644 install/upgrade16.php diff --git a/install/global.php b/install/global.php index 160aede..6bbc3a7 100644 --- a/install/global.php +++ b/install/global.php @@ -90,7 +90,8 @@ $bugsys->versions = array( '1.2.0 Beta 2' => 13, '1.2.0 Beta 3' => 14, '1.2.0 Release Candidate 1' => 15, - '1.2.0' => -1 + '1.2.0' => 16, + '1.2.1' => -1 ); // ################################################################### diff --git a/install/upgrade.php b/install/upgrade.php index 8a96a7a..c860bec 100644 --- a/install/upgrade.php +++ b/install/upgrade.php @@ -30,7 +30,13 @@ if (!isset($bugsys->in['next'])) $version = $db->query_first("SELECT * FROM " . TABLE_PREFIX . "setting WHERE varname = 'trackerversion'"); $version = $version['value']; - if (!$version OR $version == '[#]version[#]') + if ($version == '[#]version[#]') + { + header('Location: upgrade16.php') + exit; + } + + if (!$version) { die('You have done something to your database and this script cannot determine Bugdar\'s version... or you have no upgrade to perform...'); } diff --git a/install/upgrade16.php b/install/upgrade16.php new file mode 100644 index 0000000..010e105 --- /dev/null +++ b/install/upgrade16.php @@ -0,0 +1,75 @@ +in['mark'] == 0) +{ +?> +

Welcome to Bugdar

+ +

This upgrade will take from Bugdar 1.2.0 to Bugdar 1.2.1.

+ +

To begin the process, please click the button below.

+in['mark'] == 1) +{ +?> +

Version Number Change

+ +

This step finishes the upgrade by inreasing your version number.

+ +query("UPDATE " . TABLE_PREFIX . "setting SET value = '1.2.1' WHERE varname = 'trackerversion'"); + + build_settings(); + +?> + +... done. + + \ No newline at end of file -- 2.22.5