X-Git-Url: http://git.shiar.nl/minimedit.git/blobdiff_plain/20ead233cabc8fefcd86bd99f08dadc261669300..b3aec6cf1cd18493d44cf68d88c8f55b6a417f9c:/login/index.php diff --git a/login/index.php b/login/index.php index 8b4c223..66cb0c9 100644 --- a/login/index.php +++ b/login/index.php @@ -36,21 +36,31 @@ elseif (isset($_GET['logout'])) { } if (empty($User)) { - ob_clean(); require_once 'login/form.inc.php'; $Place['warn'] = $message; - return TRUE; + $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; } if (isset($_REQUEST['goto'])) { - ob_clean(); $target = ltrim($_REQUEST['goto'], '/'); header("Location: /$target"); http_response_code(302); exit; } -if (empty($Args) and !empty($User['admin'])) { +if (isset($Article->raw)) { + print $Article->raw; +} +if (empty($Args) and $User and $User->admin) { include_once 'login/admin.html'; } +return;