diff --git a/app/helpers/sanitize.php b/app/helpers/sanitize.php index 8b6e8a7..6cff317 100644 --- a/app/helpers/sanitize.php +++ b/app/helpers/sanitize.php @@ -21,13 +21,6 @@ if (isset($_REQUEST['until_time'])) { $until_time = htmlspecialchars($_REQUEST['until_time']); } -if (isset($_SESSION['notice'])) { - $notice = htmlspecialchars($_SESSION['notice']); // 'notice' for all non-critical messages -} -if (isset($_SESSION['error'])) { - $error = htmlspecialchars($_SESSION['error']); // 'error' for errors -} - // hosts if (isset($_POST['address'])) { $address = htmlspecialchars($_POST['address']); diff --git a/app/templates/block-message.php b/app/templates/block-message.php index f1b7562..35d52f0 100644 --- a/app/templates/block-message.php +++ b/app/templates/block-message.php @@ -1,7 +1,13 @@ - -
- + -
- +// 'notice' for all non-critical messages +if (isset($_SESSION['error'])) { + echo "\t\t" . '
' . $_SESSION['error'] . '
'; +} + +// 'error' for errors +if (isset($_SESSION['notice'])) { + echo "\t\t" . '
' . $_SESSION['notice'] . '
'; +} + +?>