diff --git a/assets/css/page/vacances.css b/assets/css/page/vacances.css index 10c5a1a..b762a2c 100644 --- a/assets/css/page/vacances.css +++ b/assets/css/page/vacances.css @@ -1,9 +1,24 @@ -* { +main { text-align: center; + width: 100vw; } -.mot_croise { - float: left; - width: 45vw; +section { + display: inline-block; + background-color: rgba(255,255,255,0.3); + aspect-ratio: 425/600; + width: 43vw; + margin: 1vw; + margin-top: 60px; +} + +img { + width: 100%; background-color: white; +} + +@media (max-width: 1500px) { + section { + width: 90vw; + } } \ No newline at end of file diff --git a/vacances.php b/vacances.php index 8b2896b..a8d67e5 100644 --- a/vacances.php +++ b/vacances.php @@ -1,5 +1,32 @@ query('SELECT id, name FROM mot_croise'); + while($r = $req->fetch()) { + $input[$r['id']] = htmlspecialchars($_POST["input".$r['id']]); + if(htmlspecialchars($_POST["input".$r['id']]) == $r['name']) { + $color[$r['id']] = "green"; + } elseif(!empty($_POST["input".$r['id']])) { + $color[$r['id']] = "red"; + } else { + $color[$r['id']] = "grey"; + } + } + + $end = true; + $i = 1; + + while($end AND $i <= count($color)) { + if($color[$i] != "green") { + $end = false; + } + $i++; + } +} ?>
@@ -10,8 +37,35 @@ ob_start(); // Start reading html -
- +
+
+ +
+
+ Tout les mots doivent être indiqués en minuscule, sans accent, sans espaces ni caractères spéciaux. +
+ query('SELECT id FROM mot_croise'); + + while($r = $req->fetch()) { + ?> +
+ + Franchement GG à vous, choisissez votre équipe ci-dessous pour lui faire remporter les points + + + +
+