From ad0110ca338d98386972f2320cae55adfba96925 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Sat, 5 Mar 2022 10:31:07 +0100 Subject: [PATCH] For plugin , send a NOCONX when the session is expired instead of stopping --- html/ajax.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/html/ajax.php b/html/ajax.php index 76bb6a257..7d8f3cf21 100644 --- a/html/ajax.php +++ b/html/ajax.php @@ -22,7 +22,13 @@ if ( !isset ($_REQUEST['gDossier'])) exit(); require_once NOALYSS_INCLUDE.'/class/noalyss_parameter_folder.class.php'; mb_internal_encoding("UTF-8"); - +/** + * if not connected, session is expired then exit with a message NOCONX + */ +if ( ! isset($_SESSION[SESSION_KEY."g_user"])) { + echo "NOCONX"; + die(); +} global $g_user,$cn,$g_parameter; $cn=Dossier::connect(); $g_parameter=new Noalyss_Parameter_Folder($cn);