diff --git a/html/index.php b/html/index.php index 242fece..af46480 100644 --- a/html/index.php +++ b/html/index.php @@ -18,9 +18,28 @@ require_once("../src/functions.php"); $arenas=get_arenas_list(); $lang=get_language_array(); + + +if(isset($_GET['arena'])){ + //check if arena is list + $currentArena = false; + foreach($arenas as $arena){ + if($arena['id'] == $GET['arena']){ + $currentArena = $GET['arena']; + break; + } + } + if(!$currentArena){ + error("Wrong parameter"); + die; + } +}else{ + $currentArena = ""; +} + + //form submitting -if (isset($_POST['xd_check'])) -{ +if (isset($_POST['xd_check'])){ //vérifier le numero de formulaire if (($_SESSION['xd_check']!=$_POST['xd_check']) AND ($_POST['xd_check'] !="")){ erreur ('Something wrong has appen'); @@ -51,7 +70,18 @@ if (isset($_POST['xd_check']))
- + +