Évènements

Rechercher un évènement'; if ($role == 'Organisateur') { echo ''; } $query = "SELECT * FROM event"; if (isset($_GET['sort'])) { $sort = $_GET['sort']; switch ($sort) { case 'date': $query .= " ORDER BY date"; break; case 'location': $query .= " ORDER BY location"; break; case 'discipline': $query .= " ORDER BY event_type"; break; default: break; } } // Menu déroulant pour sélectionner le tri echo "
"; echo ""; echo ""; echo "
"; $result = mysqli_query($db, $query); echo "
"; echo "
"; echo ""; echo ""; // En-tête du tableau echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; while ($row = mysqli_fetch_array($result)) { echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; if (isset($_COOKIE['userData'])) { if ($role == 'Sportif') { echo ""; } } echo ""; } echo ""; echo "
TitreDescriptionDisciplineDateLieuAction
" . htmlspecialchars($row['title']) . "" . htmlspecialchars($row['description']) . "" . htmlspecialchars($row['event_type']) . "" . date('d/m/Y', strtotime($row['date'])) . "" . htmlspecialchars($row['location']) . "
"; echo "
"; echo "
"; ?>