Correction de lien
continuous-integration/drone/push Build is failing Details

ServeurDeTest
Noé GARNIER 2 years ago
parent 2464467ae1
commit d00ee47e77

@ -42,6 +42,7 @@ $vues['queue'] = 'View/src/pages/Multijoueur/FileAttente.php';
$vues['lobby'] = 'View/src/pages/Multijoueur/Lobby.php';
$vues['lobbyEnd'] = 'View/src/pages/Multijoueur/LobbyEnd.php';
$vues['gameEnd'] = 'View/src/pages/Multijoueur/GameEnd.php';
$vues['dashboard'] = 'View/src/pages/Multijoueur/Dashboard.html';
// Enigme
$vues['enigmePage'] = 'View/src/pages/Enigme/EnigmePage.php';

@ -73,6 +73,9 @@ class UserController
case "skipEnigme":
$this->skipEnigme();
break;
case "goToDashboard":
$this->goToDashboard();
break;
default:
$error = "Action non valide";
require($rep . $vues['erreur']);
@ -106,6 +109,16 @@ class UserController
require($rep . $vues['erreur']);
}
}
public function goToDashboard()
{
try {
global $rep, $vues;
require($rep . $vues['dashboard']);
} catch (Exception $e) {
$error = $e->getMessage();
require($rep . $vues['erreur']);
}
}
public function goToSolo()
{
try {

@ -131,5 +131,5 @@ function displayHelp() {
* It opens a new window with the name dashboard.html and the size of 1000x450.
*/
function dashboard() {
window.open("dashboard.html", "", "width=1000, height=450");
window.open("index.php?action=goToDashboard", "", "width=1000, height=450");
}
Loading…
Cancel
Save