diff options
author | Frederic Guillot <fred@kanboard.net> | 2015-09-05 17:06:01 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2015-09-05 17:06:01 -0400 |
commit | 70d3340cd0c9d7a009c186b14ca436e9c4e61aa5 (patch) | |
tree | 2fd898d99e73d79607beb72f57cbd706f238f976 /app/Core/Response.php | |
parent | ccaf78b3484134336212780587835befa8759096 (diff) |
Creating another task stay in the popover
Diffstat (limited to 'app/Core/Response.php')
-rw-r--r-- | app/Core/Response.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/app/Core/Response.php b/app/Core/Response.php index d42a8f1e..f8ca015c 100644 --- a/app/Core/Response.php +++ b/app/Core/Response.php @@ -66,7 +66,13 @@ class Response */ public function redirect($url) { - header('Location: '.$url); + if (isset($_SERVER['HTTP_X_REQUESTED_WITH']) && $_SERVER['HTTP_X_REQUESTED_WITH'] === 'XMLHttpRequest') { + header('X-Ajax-Redirect: '.$url); + } + else { + header('Location: '.$url); + } + exit; } |