PLANNING DES BÉNÉGRÔLES
connect_error) {
die("Connection failed: " . $conn->connect_error);
}
// Ajouter un bénévole au planning
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$benevole_id = $_POST['benevole_id'];
$pole_id = $_POST['pole_id'];
$horaire_start = $_POST['horaire_start'];
$horaire_end = $_POST['horaire_end'];
$sql = "INSERT INTO planning (benevole_id, pole_id, horaire_start, horaire_end)
VALUES ('$benevole_id', '$pole_id', '$horaire_start', '$horaire_end')";
if ($conn->query($sql) === TRUE) {
echo "Planning Festival
";
echo "
";
} else {
echo "
Le planning a été mis à jour avec succès.
"; } else { echo "Erreur: " . $sql . "
" . $conn->error . "
Gestion du Planning du Festival
Planning des bénévoles
num_rows > 0) { echo "| Pôle | Bénévole | Horaire de début | Horaire de fin |
|---|---|---|---|
| " . $row["pole"]. " | " . $row["benevole"]. " | " . $row["horaire_start"]. " | " . $row["horaire_end"]. " |
Aucun planning trouvé.
"; } ?>
