forked from Apps/WebAppTemplate
Add message if user is kicked out of application for lack of permissions
This commit is contained in:
parent
8e65d4c98d
commit
dafc3b76ea
@ -1,5 +1,4 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
@ -9,10 +8,14 @@ require_once __DIR__ . "/required.php";
|
|||||||
require_once __DIR__ . "/lib/login.php";
|
require_once __DIR__ . "/lib/login.php";
|
||||||
|
|
||||||
// if we're logged in, we don't need to be here.
|
// if we're logged in, we don't need to be here.
|
||||||
if ($_SESSION['loggedin']) {
|
if ($_SESSION['loggedin'] && !isset($_GET['permissionerror'])) {
|
||||||
header('Location: app.php');
|
header('Location: app.php');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isset($_GET['permissionerror'])) {
|
||||||
|
$alert = lang("no permission", false);
|
||||||
|
}
|
||||||
|
|
||||||
/* Authenticate user */
|
/* Authenticate user */
|
||||||
$userpass_ok = false;
|
$userpass_ok = false;
|
||||||
$multiauth = false;
|
$multiauth = false;
|
||||||
|
@ -28,6 +28,7 @@ define("STRINGS", [
|
|||||||
"login server error" => "The login server returned an error: {arg}",
|
"login server error" => "The login server returned an error: {arg}",
|
||||||
"login server user data error" => "The login server refused to provide account information. Try again or contact technical support.",
|
"login server user data error" => "The login server refused to provide account information. Try again or contact technical support.",
|
||||||
"captcha error" => "There was a problem with the CAPTCHA (robot test). Try again.",
|
"captcha error" => "There was a problem with the CAPTCHA (robot test). Try again.",
|
||||||
|
"no permission" => "You don't have permission to do that.",
|
||||||
"home" => "Home",
|
"home" => "Home",
|
||||||
"more" => "More",
|
"more" => "More",
|
||||||
"test" => "Test"
|
"test" => "Test"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user