|
Revision 1739, 1.2 KB
(checked in by driehle, 4 months ago)
|
|
Some Bugfixes for old Jlog-Versions
|
| Line | |
|---|
| 1 | <?php |
|---|
| 2 | ### update.php Jlog 1.0.2 => Jlog 1.1.0 |
|---|
| 3 | |
|---|
| 4 | define("JLOG_ADMIN", true); |
|---|
| 5 | define("JLOG_UPDATE", true); |
|---|
| 6 | |
|---|
| 7 | // load prepend.inc.php |
|---|
| 8 | require_once('..'.DIRECTORY_SEPARATOR.'scripts'.DIRECTORY_SEPARATOR.'prepend.inc.php'); |
|---|
| 9 | |
|---|
| 10 | include(JLOG_BASEPATH.'lang'.DIRECTORY_SEPARATOR.'lang.'.JLOG_LANGUAGE.'.inc.php'); |
|---|
| 11 | include(JLOG_BASEPATH.'lang'.DIRECTORY_SEPARATOR.'lang-admin.'.JLOG_LANGUAGE.'.inc.php'); |
|---|
| 12 | |
|---|
| 13 | // Rendering |
|---|
| 14 | $c['meta']['title'] = "Update"; |
|---|
| 15 | //$c['main'] = sprintf("<h2>Update von <var>%s</var> auf <var>%s</var></h2>", JLOG_INSTALLED_VERSION, JLOG_SOFTWARE_VERSION); |
|---|
| 16 | |
|---|
| 17 | require_once(JLOG_BASEPATH.'scripts'.DIRECTORY_SEPARATOR.'JlogUpdater.php'); |
|---|
| 18 | $updater = new JlogUpdater(); |
|---|
| 19 | |
|---|
| 20 | if ($updater->isUp2Date()) { |
|---|
| 21 | $c['main'] = '<p>Das Update auf ' . JLOG_INSTALLED_VERSION . ' wurde bereits erfolgreich durchgefÃŒhrt.</p>'; |
|---|
| 22 | } |
|---|
| 23 | else if (!isset($_POST['update'])) { |
|---|
| 24 | $c['main'] = $updater->prepareForm($l); |
|---|
| 25 | } |
|---|
| 26 | else { |
|---|
| 27 | $c['main'] = $updater->performUpdate($l); |
|---|
| 28 | |
|---|
| 29 | // Ready :-) |
|---|
| 30 | require(JLOG_BASEPATH."scripts".DIRECTORY_SEPARATOR."update.php"); |
|---|
| 31 | } |
|---|
| 32 | |
|---|
| 33 | require(JLOG_BASEPATH.'scripts'.DIRECTORY_SEPARATOR.'do_template.php'); |
|---|
| 34 | echo $body; |
|---|
| 35 | ?> |
|---|