From d3479236d9127efc377dd032ace7e7cb4599b6fb Mon Sep 17 00:00:00 2001 From: grouille Date: Tue, 28 Apr 2020 12:08:24 +0200 Subject: [PATCH] MAJ --- site/accesBase.php | 19 +++++++++++++++++++ site/formSuppression.php | 1 - site/inscrire.php | 41 ++++++++++++++++++++++++++++++++++++++++- 3 files changed, 59 insertions(+), 2 deletions(-) diff --git a/site/accesBase.php b/site/accesBase.php index 7dce86d..4bed644 100644 --- a/site/accesBase.php +++ b/site/accesBase.php @@ -44,6 +44,15 @@ $result = pg_query($db, $query) or die("La requête a echoué : ".pg_last_error()); return pg_affected_rows($result); } + + function members() + { + $db = connexion(); + $query = "SELECT * FROM membres"; + $result = pg_query($db, $query) or die("La requête a echoué : ".pg_last_error()); + $tab = pg_fetch_all($result); + return $tab; + } function inscription($id, $pwd, $nom, $prenom, $groupe) { @@ -83,6 +92,16 @@ return $tab['groupe']; } + function groupeId($id) + { + $db = connexion(); + $query = "SELECT groupe FROM groupes where id = '$id'"; + $result = pg_query($db, $query) or die("La requête a echoué : ".pg_last_error()); + $tab = pg_fetch_assoc($result); + deconnexion($db); + return $tab['groupe']; + } + function getGroupes() { $db = connexion(); diff --git a/site/formSuppression.php b/site/formSuppression.php index e81f4f0..5cab4a2 100644 --- a/site/formSuppression.php +++ b/site/formSuppression.php @@ -1,7 +1,6 @@
diff --git a/site/inscrire.php b/site/inscrire.php index 6b6023b..c5e75e0 100644 --- a/site/inscrire.php +++ b/site/inscrire.php @@ -1,5 +1,7 @@ @@ -13,9 +15,46 @@ session_start(); +
+
+
+

Membres

+ + + + + + + + + + + + + + + + + + + + +
NomPrénomIdentifiantGroupeAction
+
+ + +
+
+
+
+