diff --git a/Project/php/controller/AbsController.php b/Project/php/controller/AbsController.php index 0515142..ea9c81b 100644 --- a/Project/php/controller/AbsController.php +++ b/Project/php/controller/AbsController.php @@ -128,4 +128,9 @@ class AbsController $mdl->deconnection(); $this->home(); } + + public function resultatsJeux(): void{ + global $twig; + echo $twig->render('resultatsJeux.html'); + } } \ No newline at end of file diff --git a/Project/php/js/memory.js b/Project/php/js/memory.js index 73c4b83..f0d0923 100644 --- a/Project/php/js/memory.js +++ b/Project/php/js/memory.js @@ -74,7 +74,7 @@ document.addEventListener('DOMContentLoaded', function () { function checkGameCompletion(){ if (document.querySelectorAll('.card.found').length === cards.length) { - window.location.href = '../../templates/resultatsJeux.html'; // A MODIFIER POUR UN TWIG RENDER + window.location.href = '../resultatsJeux'; // A MODIFIER POUR UN TWIG RENDER } } }); \ No newline at end of file diff --git a/Project/php/templates/resultatsJeux.html b/Project/php/templates/resultatsJeux.html index 8994d41..d0e8e5d 100644 --- a/Project/php/templates/resultatsJeux.html +++ b/Project/php/templates/resultatsJeux.html @@ -12,7 +12,7 @@ justify-content: center; height: 100vh; margin: 0; - background: url('{{base}}/assets/img/points.png') center/cover no-repeat; + background: url('../assets/img/points.png') center/cover no-repeat; background-color: lightslategray; } @@ -47,7 +47,7 @@
-