diff --git a/functions.php b/functions.php
index 9d06da1..df165a3 100644
--- a/functions.php
+++ b/functions.php
@@ -148,7 +148,7 @@ function show_service_update($name, $update, $uptodate) {
if (!empty($update)) {
$arr = explode(" ",$update);
foreach ($arr as $container) {
- $str .= "
| ".$container." | UPDATE AVAILABLE | UPDATE |
";
+ $str .= " | ".$container." | UPDATE AVAILABLE | UPDATE |
";
}
}
diff --git a/manage.html b/manage.html
index 0805d06..1488d85 100644
--- a/manage.html
+++ b/manage.html
@@ -279,13 +279,6 @@ function get_updates() {
});
}
-function update(service) {
- if (service=='framework') {
- framework_upgrade();
- }
- else alert(service+' update under construction');
-}
-
function check_upgrade() {
var url = 'scan.php?op=check_upgrade';
jQuery.get(url, function(data) {
@@ -299,10 +292,11 @@ function check_upgrade() {
});
}
-function framework_upgrade() {
- var url = 'scan.php?op=upgrade';
+function upgrade(service) {
+ var url = 'scan.php?op=upgrade&service='+service;
+ console.log('upgrade start: '+service);
jQuery.get(url, function(data) {
- console.log('framework upgrade: '+data);
+ console.log('upgrade end: '+service);
if (data=="OK") {
setTimeout(check_upgrade, 1000);
}
diff --git a/scan.php b/scan.php
index f3eb8d0..6fac534 100644
--- a/scan.php
+++ b/scan.php
@@ -389,7 +389,7 @@ switch ($_GET["op"]) {
else echo "WAIT";
break;
case "upgrade":
- $arr = array("NAME" => "framework", "ACTION" => "upgrade");
+ $arr = array("NAME" => $_GET["service"], "ACTION" => "upgrade");
$json = json_encode($arr, JSON_UNESCAPED_SLASHES|JSON_PRETTY_PRINT);
if (set_output("upgrade",$json)) echo "OK";