diff --git a/web/bulk/restore/index.php b/web/bulk/restore/index.php index f55e89192..80c026cf1 100644 --- a/web/bulk/restore/index.php +++ b/web/bulk/restore/index.php @@ -26,14 +26,14 @@ if (!empty($_POST['udir'])) $udir = escapeshellarg(implode(",",$_POST['udir'])); if ($action == 'restore') { exec (VESTA_CMD."v-schedule-user-restore ".$user." ".$backup." ".$web." ".$dns." ".$mail." ".$db." ".$cron." ".$udir, $output, $return_var); if ($return_var == 0) { - $_SESSION['restore_msg'] = __('RESTORE_SCHEDULED'); + $_SESSION['error_msg'] = __('RESTORE_SCHEDULED'); } else { - $_SESSION['restore_msg'] = implode('
', $output); - if (empty($_SESSION['restore_msg'])) { - $_SESSION['restore_msg'] = __('Error: vesta did not return any output.'); + $_SESSION['error_msg'] = implode('
', $output); + if (empty($_SESSION['error_msg'])) { + $_SESSION['error_msg'] = __('Error: vesta did not return any output.'); } if ($return_var == 4) { - $_SESSION['restore_msg'] = __('RESTORE_EXISTS'); + $_SESSION['error_msg'] = __('RESTORE_EXISTS'); } } } diff --git a/web/inc/main.php b/web/inc/main.php index e44ffbcba..abd34fb26 100644 --- a/web/inc/main.php +++ b/web/inc/main.php @@ -213,23 +213,24 @@ function send_email($to,$subject,$mailtext,$from) { function display_error_block() { if (!empty($_SESSION['error_msg'])) { echo ' - -
-

'; - echo $_SESSION['error_msg']; - echo "

\n
\n"; +
+ +
+

'. $_SESSION['error_msg'] .'

+
+
'."\n"; unset($_SESSION['error_msg']); } } diff --git a/web/restart/service/index.php b/web/restart/service/index.php index 923d1c067..3e18e3d37 100644 --- a/web/restart/service/index.php +++ b/web/restart/service/index.php @@ -13,7 +13,7 @@ if ($_SESSION['user'] == 'admin') { if ($return_var != 0) { $error = implode('
', $output); if (empty($error)) $error = __('SERVICE_ACTION_FAILED',__('restart'),$v_service); - $_SESSION['error_srv'] = $error; + $_SESSION['error_msg'] = $error; } unset($output); } diff --git a/web/restart/system/index.php b/web/restart/system/index.php index 2ef5c1850..0b761254c 100644 --- a/web/restart/system/index.php +++ b/web/restart/system/index.php @@ -8,7 +8,7 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); if ($_SESSION['user'] == 'admin') { if (!empty($_GET['hostname'])) { exec (VESTA_CMD."v-restart-system yes", $output, $return_var); - $_SESSION['error_srv'] = 'The system is going down for reboot NOW!'; + $_SESSION['error_msg'] = 'The system is going down for reboot NOW!'; } unset($output); } diff --git a/web/schedule/backup/index.php b/web/schedule/backup/index.php index 15cb2d206..67c7b44ff 100644 --- a/web/schedule/backup/index.php +++ b/web/schedule/backup/index.php @@ -8,15 +8,15 @@ include($_SERVER['DOCUMENT_ROOT']."/inc/main.php"); $v_username = escapeshellarg($user); exec (VESTA_CMD."v-schedule-user-backup ".$v_username, $output, $return_var); if ($return_var == 0) { - $_SESSION['backup_msg'] = __('BACKUP_SCHEDULED'); + $_SESSION['error_msg'] = __('BACKUP_SCHEDULED'); } else { - $_SESSION['backup_msg'] = implode('
', $output); - if (empty($_SESSION['backup_msg'])) { - $_SESSION['backup_msg'] = __('Error: vesta did not return any output.'); + $_SESSION['error_msg'] = implode('
', $output); + if (empty($_SESSION['error_msg'])) { + $_SESSION['error_msg'] = __('Error: vesta did not return any output.'); } if ($return_var == 4) { - $_SESSION['backup_msg'] = __('BACKUP_EXISTS'); + $_SESSION['error_msg'] = __('BACKUP_EXISTS'); } } diff --git a/web/schedule/restore/index.php b/web/schedule/restore/index.php index c37c8046f..ce7d5d03d 100644 --- a/web/schedule/restore/index.php +++ b/web/schedule/restore/index.php @@ -30,14 +30,14 @@ if (!empty($_GET['type'])) { exec ($restore_cmd, $output, $return_var); if ($return_var == 0) { - $_SESSION['restore_msg'] = __('RESTORE_SCHEDULED'); + $_SESSION['error_msg'] = __('RESTORE_SCHEDULED'); } else { - $_SESSION['restore_msg'] = implode('
', $output); - if (empty($_SESSION['restore_msg'])) { - $_SESSION['restore_msg'] = __('Error: vesta did not return any output.'); + $_SESSION['error_msg'] = implode('
', $output); + if (empty($_SESSION['error_msg'])) { + $_SESSION['error_msg'] = __('Error: vesta did not return any output.'); } if ($return_var == 4) { - $_SESSION['restore_msg'] = __('RESTORE_EXISTS'); + $_SESSION['error_msg'] = __('RESTORE_EXISTS'); } } diff --git a/web/update/vesta/index.php b/web/update/vesta/index.php index d1d22f613..a025c7bf0 100644 --- a/web/update/vesta/index.php +++ b/web/update/vesta/index.php @@ -14,7 +14,7 @@ if ($_SESSION['user'] == 'admin') { if ($return_var != 0) { $error = implode('
', $output); if (empty($error)) $error = 'Error: '.$v_pkg.' update failed'; - $_SESSION['error_upd'] = $error; + $_SESSION['error_msg'] = $error; } unset($output); }