Bridge Edit: Use message object instead of session var.

This commit is contained in:
Nate 2019-09-17 21:34:20 -06:00
parent b3d6db4b6b
commit 4b669970f2
1 changed files with 3 additions and 3 deletions

View File

@ -64,8 +64,8 @@
//validate the token //validate the token
$token = new token; $token = new token;
if (!$token->validate('/app/bridges/bridge_edit.php')) { if (!$token->validate($_SERVER['PHP_SELF'])) {
$_SESSION["message"] = $text['message-invalid_token']; message::add($text['message-invalid_token'],'negative');
header('Location: bridges.php'); header('Location: bridges.php');
exit; exit;
} }
@ -138,7 +138,7 @@
//create token //create token
$object = new token; $object = new token;
$token = $object->create('/app/bridges/bridge_edit.php'); $token = $object->create($_SERVER['PHP_SELF']);
//show the header //show the header
require_once "resources/header.php"; require_once "resources/header.php";