From ea2ac937aa3cb2e59bdd5174f9485e51339d50fc Mon Sep 17 00:00:00 2001 From: Louis GUICHARD-MONTGUERS Date: Fri, 22 Nov 2024 13:30:29 +0100 Subject: [PATCH] Supprimer 'src/Controleur/QuizControler.php' --- src/Controleur/QuizControler.php | 70 -------------------------------- 1 file changed, 70 deletions(-) delete mode 100644 src/Controleur/QuizControler.php diff --git a/src/Controleur/QuizControler.php b/src/Controleur/QuizControler.php deleted file mode 100644 index 318a7f2..0000000 --- a/src/Controleur/QuizControler.php +++ /dev/null @@ -1,70 +0,0 @@ - co = $co; - $this -> gw = new QuestionGateway($this -> co); - $this -> mdl = new QuestionModel($this -> gw); - global $num; - global $loader; - - $action = $_REQUEST['action'] ?? null; - - $id = (int) explode('/', $_SERVER['REQUEST_URI'])[2] ?? null; - echo $id; - $nb_questions = $this->getNumberOfQuestion($id); - - switch ($action) { - case 'canswer': - if ($this->CorrectAnswer()) - $_SESSION['score'] = isset($_SESSION['score']) ? ($_SESSION['score'] + 1) : 1; - $this->continueQuiz($id, $nb_questions); - break; - default: - switch($id) - { - case null: - // page erreur - break; - default: - $_SESSION['score'] = $_SESSION['score'] ?? 0; - $this->showQuestion($id, $_SESSION['no_question'] ?? 0); - break; - } - } - - } - - - -} \ No newline at end of file