From 897053e049a4c822ac59baec777f4898965c1c51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philip=20H=C3=A4usler?= Date: Sun, 27 Dec 2015 23:20:09 +0100 Subject: [PATCH] redirect to users profile page after marking as arrived or not arrived --- includes/pages/admin_arrive.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/includes/pages/admin_arrive.php b/includes/pages/admin_arrive.php index c7fcab63..a061df6a 100644 --- a/includes/pages/admin_arrive.php +++ b/includes/pages/admin_arrive.php @@ -16,7 +16,8 @@ function admin_arrive() { if ($user_source != null) { sql_query("UPDATE `User` SET `Gekommen`=0, `arrival_date` = NULL WHERE `UID`='" . sql_escape($id) . "' LIMIT 1"); engelsystem_log("User set to not arrived: " . User_Nick_render($user_source)); - $msg = success(_("Reset done. Angel has not arrived."), true); + success(_("Reset done. Angel has not arrived.")); + redirect(user_link($user_source)); } else $msg = error(_("Angel not found."), true); } elseif (isset($_REQUEST['arrived']) && preg_match("/^[0-9]*$/", $_REQUEST['arrived'])) { @@ -25,7 +26,8 @@ function admin_arrive() { if ($user_source != null) { sql_query("UPDATE `User` SET `Gekommen`=1, `arrival_date`='" . time() . "' WHERE `UID`='" . sql_escape($id) . "' LIMIT 1"); engelsystem_log("User set has arrived: " . User_Nick_render($user_source)); - $msg = success(_("Angel has been marked as arrived."), true); + success(_("Angel has been marked as arrived.")); + redirect(user_link($user_source)); } else $msg = error(_("Angel not found."), true); }