forked from rebillar/site-accueil-insa
Compare commits
2 commits
a081f946ec
...
05d81c32ed
Author | SHA1 | Date | |
---|---|---|---|
|
05d81c32ed | ||
|
f9296798c1 |
2 changed files with 23 additions and 5 deletions
|
@ -18,6 +18,23 @@ if(isset($_POST['start2'])) {
|
|||
header('Refresh: 0');
|
||||
}
|
||||
|
||||
/*
|
||||
TODO : FAIRE UN SCRIPT POUR AJOUTER DES EPREUVES ET EQUIPES DEPUIS LE PANEAU D'ADMIN
|
||||
*/
|
||||
|
||||
// ajout d'une epreuve
|
||||
if(isset($_POST['add_epreuve'])){
|
||||
$req = $db->prepare("INSERT INTO ville_equipe(indice,reponse,photo) VALUES(?,?,?)");
|
||||
$req->execute($_POST['indice'],$_POST['reponse'],'assets/img/ville/'.htmlspecialchars($_POST['photo']));
|
||||
}
|
||||
|
||||
//ajout d'une equipe
|
||||
if(isset($_POST['add_equipe'])){
|
||||
$req = $db->prepare("INSERT INTO ville_equipe(nom,begin,temps) VALUES(?,?,?)");
|
||||
$req->execute($_POST['nom'],$_POST['begin'],$_POST['temps']);
|
||||
}
|
||||
|
||||
|
||||
if(isset($_POST['stop1'])) {
|
||||
$req = $db->query("UPDATE ville SET state = 2 WHERE session = 1");
|
||||
header('Refresh: 0');
|
||||
|
@ -56,16 +73,17 @@ if(isset($_POST['reset2'])) {
|
|||
|
||||
|
||||
|
||||
|
||||
<?php
|
||||
/*
|
||||
TODO : FAIRE UN SCRIPT POUR AJOUTER DES EPREUVES ET EQUIPES DEPUIS LE PANEAU D'ADMIN
|
||||
*/
|
||||
|
||||
|
||||
|
||||
if(isset($_GET['session']) AND !empty($_GET['session']))
|
||||
{
|
||||
$session = (int) htmlspecialchars($_GET['session']);
|
||||
if($session == 1) {
|
||||
?>
|
||||
|
||||
<form me
|
||||
<a href="ville.php?session=1" class="href_session_selected">Session matin</a>
|
||||
<a href="ville.php?session=2" class="href_session">Session aprem</a>
|
||||
<br>
|
||||
|
|
|
@ -35,7 +35,7 @@ for($i = 0; $i <= 17; $i++){
|
|||
|
||||
<!-- la barre de navigation -->
|
||||
<div class="topnav">
|
||||
<a href="/index.php" class="active">P'tit menu :)</a>
|
||||
<a href="index.php" class="active">P'tit menu :)</a>
|
||||
|
||||
<!-- les liens (cachés par défaut) -->
|
||||
<div id="mobile_menu_links">
|
||||
|
|
Loading…
Reference in a new issue