From a38230db40708cb7aeaf5d6e028a3939fd71c23a Mon Sep 17 00:00:00 2001 From: lars Date: Mon, 11 Mar 2019 13:47:58 +0100 Subject: [PATCH] =?UTF-8?q?Changement=20du=20header()=20=C3=A0=20une=20sol?= =?UTF-8?q?ution=20Javascript?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- accred_form.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/accred_form.php b/accred_form.php index 0c06350d..a45945dd 100644 --- a/accred_form.php +++ b/accred_form.php @@ -2,7 +2,7 @@ require_once 'vendor/autoload.php'; ini_set('display_errors', 0); ini_set('display_startup_errors', 0); - error_reporting(E_ALL & ~E_NOTICE ); + error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED & ~E_WARNING ); session_start(); $userid = $_SESSION['uid']; @@ -14,12 +14,12 @@ require_once 'vendor/autoload.php'; $isEditable = $_SESSION['allowedit']==1; if(!$userid) { syslog(LOG_ERR, "Unauthorized access to form page aid:$aid from : {$_SERVER['REMOTE_ADDR']} ({$_SERVER['HTTP_USER_AGENT']})"); - header('Location: accred_list'); + echo ""; die(); } if(!$isAdmin && $isEditable!=1) { syslog(LOG_ERR, "Unauthorized access to form page aid by non editable user :$aid from : {$_SERVER['REMOTE_ADDR']} ({$_SERVER['HTTP_USER_AGENT']})"); - header('Location: accred_list'); + echo ""; die(); } @@ -27,7 +27,7 @@ require_once 'vendor/autoload.php'; $uname = $_SESSION['name']; if($_POST['btncancel']) { - header('Location: accred_list'); + echo ""; die(); } $prices = array( @@ -138,8 +138,7 @@ if (!$mysqli->query($query) ) { echo "Table creation failed: (" . $mysqli->errno . ") " . $mysqli->error; die("Argh"); } - -header('Location: accred_list'); +echo ""; die(); }