X-Git-Url: http://git.shiar.net/minimedit.git/blobdiff_plain/0c5eed59b9187f54cedadc383bf2326f5ba354e0..41811556ca2ca3ca29191bee012c35e5f40a3995:/login/index.php diff --git a/login/index.php b/login/index.php index 86af074..5cfbded 100644 --- a/login/index.php +++ b/login/index.php @@ -39,18 +39,26 @@ if (empty($User)) { ob_clean(); require_once 'login/form.inc.php'; $Place['warn'] = $message; + $Article->title = 'Inloggen'; + if (isset($_REQUEST['goto'])) { + $target = ltrim($_REQUEST['goto'], '/'); + $target = new ArchiveArticle("$target.html"); + if ($target->title) { + $Article->title .= ' voor ' . $target->title; + } + } return TRUE; } -if (isset($_GET['goto'])) { +if (isset($_REQUEST['goto'])) { ob_clean(); - $target = ltrim($_GET['goto'], '/'); + $target = ltrim($_REQUEST['goto'], '/'); header("Location: /$target"); http_response_code(302); exit; } -if (empty($Args) and !empty($User['admin'])) { +if (empty($Args) and $User and $User->admin) { include_once 'login/admin.html'; }