Correctif : SKIP sur présentation + Help sur la div dans énigme

ServeurDeTest
nathan boileau 2 years ago
parent c1c24a10e5
commit c2865ef9de

@ -27,6 +27,12 @@ class EnigmeGateway
$this->con = $con;
}
/**
* It inserts a new row in the Enigme table, with the values of the Enigme object passed as
* parameter
*
* @param Enigme enigme
*/
public function insert(Enigme $enigme)
{
$query = "INSERT INTO Enigme VALUES (:id,:admin,:enonce,:aide,:rappel,:solution,:test,:tempsDeResolution,:points)";
@ -43,6 +49,12 @@ class EnigmeGateway
));
}
/**
* It deletes a row from the table Enigme where the idEnigme is equal to the idEnigme passed as a
* parameter
*
* @param string idEnigme the id of the enigma
*/
public function delete(string $idEnigme)
{
$query= "DELETE FROM Enigme WHERE idEnigme=:idEnigme";
@ -51,6 +63,12 @@ class EnigmeGateway
));
}
/**
* It returns an array of Enigme objects
* For multiplayer Enigma
*
* @return array An array of Enigme objects.
*/
public function findMultiEnigma() : array
{
$query = "SELECT * FROM Enigme
@ -60,6 +78,12 @@ class EnigmeGateway
return $tabEnigme;
}
/**
* It returns an array of Enigma objects
* For Solo enigma
*
* @return An array of objects.
*/
public function findSoloEnigma(){
$query = "SELECT * FROM Enigme
WHERE points IS NULL OR points = 0";
@ -68,6 +92,13 @@ class EnigmeGateway
return $tabEnigme;
}
/**
* It takes an idEnigme as a string, and returns an array of Enigme objects
*
* @param string idEnigme the id of the enigma
*
* @return array An array of Enigme objects.
*/
public function findById(string $idEnigme) : array
{
$query="SELECT * FROM Enigme WHERE idEnigme =:idEnigme";

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

@ -41,7 +41,7 @@ nav {
/* Section Histoire */
section{
min-height: 60vh;
min-height: 70vh;
margin-bottom: 10px;
}

@ -0,0 +1,27 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Scripted</title>
<link
rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/5.0.0-alpha1/css/bootstrap.min.css"
integrity="sha384-r4NyP46KrjDleawBgD5tp8Y7UzmLA05oM1iAEQ17CSuDqnUK2+k9luXQOfXJCJ4I"
crossorigin="anonymous"
/>
<script
src="https://cdn.jsdelivr.net/npm/popper.js@1.16.0/dist/umd/popper.min.js"
integrity="sha384-Q6E9RHvbIyZFJoft+2mJbHaEWldlvI9IOYy5n3zV9zzTtmI3UksdQRVvoxMfooAo"
crossorigin="anonymous"
></script>
<script
src="https://stackpath.bootstrapcdn.com/bootstrap/5.0.0-alpha1/js/bootstrap.min.js"
integrity="sha384-oesi62hOLfzrys4LxRF63OJCXdXDipiYWBnvTl9Y9/TRlw5xlKIEHpNyvvDShgf/"
crossorigin="anonymous"
></script>
</head>
<body>
</body>
</html>

@ -28,7 +28,6 @@
</head>
<body>
<div class="container-fluid px-5">
<!-- First Row -->
<div class="row py-4">
<div class="col-9 d-flex align-items-center px-0">
@ -40,24 +39,23 @@
>home</a
>
</div>
<div class="col-3 d-flex align-items-center">
<div class="col-10 text-right px-3">
<p style="font-size: 14px"><b>Besoin d'aide ?</b></p>
</div>
<div class="col-2 text-right">
<button
style="background-color: transparent; border: none"
onclick="displayHelp()"
class="col-3 d-flex align-items-center"
>
<div class="col-10 text-right px-3">
<p style="font-size: 14px; color: white"><b>Besoin d'aide ?</b></p>
</div>
<div class="col-2 text-right">
<img
src="View/assets/img/Foxy.png"
alt="Logo"
class="rounded-circle moving-fox"
style="border: 1px solid #44fff6; width: 60px; height: 60px"
/>
</button>
</div>
</div>
</button>
</div>
<!-- End First Row -->

@ -37,6 +37,9 @@
Northgan
</h5>
</div>
<div class="nav-link">
<a class="navbar-brand" href="index.php?action=goToEnigme">Skip</a>
</div>
<div class="nav-link">
<a class="navbar-brand" href="index.php?action=goToEnigme">Next</a>
</div>
@ -77,6 +80,15 @@
source.
</p>
</section>
<section class="hidden row" style="min-height:25vh">
<p>
Clique sur le bouton NEXT pour commencer tes premiers pas dans l'ère du developpement.
</p>
<p>
Clique sur SKIP pour aller directement aux énigmes.
</p>
</section>
</div>
<div class="col-3" id="fox">

Loading…
Cancel
Save