2026-02-24 14:26:25 +00:00
|
|
|
<?php
|
|
|
|
|
include("./Assets/functions.php");
|
2026-02-25 07:52:22 +00:00
|
|
|
$config = json_decode(file_get_contents("./Assets/config.json"), true);
|
|
|
|
|
$bdd = connectBDD("localhost", $config["BDD_USER"], $config["BDD_PASSWD"], $config["BDD_NAME"]);
|
2026-02-24 14:26:25 +00:00
|
|
|
$page = "Accueil";
|
2026-03-04 16:34:46 +00:00
|
|
|
$prefixe = $config["LOCAL_IMG_PREFIXE"]."actus/";
|
2026-02-24 14:26:25 +00:00
|
|
|
?>
|
|
|
|
|
<!doctype html>
|
|
|
|
|
<html lang="fr">
|
|
|
|
|
<head>
|
|
|
|
|
<meta charset="utf-8">
|
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
|
<title>Intranet de l'APEI</title>
|
|
|
|
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-sRIl4kxILFvY47J16cr9ZwB07vP4J8+LH7qKQnuqkuIAvNWLzeN8tE5YBujZqJLB" crossorigin="anonymous">
|
|
|
|
|
<link rel="stylesheet" href="./styles-scripts/index.css">
|
|
|
|
|
<link rel="shortcut icon" href="./Assets/Icones/APEIMBGE.jpg" type="image/x-icon">
|
|
|
|
|
</head>
|
|
|
|
|
<body>
|
|
|
|
|
<?php include('./Assets/navbar.php'); ?>
|
|
|
|
|
<!-- Carousel -->
|
|
|
|
|
<ul id="carousel" class="carousel">
|
|
|
|
|
<?php
|
|
|
|
|
$actus = getActus($bdd);
|
|
|
|
|
foreach ($actus as $actu): ?>
|
|
|
|
|
<li data-accName="<?= htmlspecialchars($actu["id"]) ?>" class="carousel">
|
|
|
|
|
<h2><?= htmlspecialchars($actu["titre"]) ?></h2>
|
|
|
|
|
|
|
|
|
|
<div class="carouselContent">
|
2026-03-04 16:34:46 +00:00
|
|
|
<img src="<?= htmlspecialchars($prefixe.$actu["image"]) ?>" alt="image de couverture">
|
2026-02-24 14:26:25 +00:00
|
|
|
<p><?= nl2br(htmlspecialchars($actu["actu"])) ?></p>
|
|
|
|
|
</div>
|
|
|
|
|
</li>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
</ul>
|
|
|
|
|
<!-- Fin carousel -->
|
|
|
|
|
<h3>Raccourcis :</h3>
|
|
|
|
|
<div class="container">
|
|
|
|
|
<?php
|
|
|
|
|
$raccourcis = getRaccourcis($bdd);
|
|
|
|
|
foreach($raccourcis as $raccourci) : ?>
|
|
|
|
|
<div class="element <?= $raccourci["nom"] ?>" onclick="window.location.href = '<?= $raccourci['url'] ?>/'" style="cursor: pointer">
|
|
|
|
|
<h3><?= $raccourci["nom"] ?></h3>
|
|
|
|
|
<img src="<?= $raccourci["image"] ?>" width='80px'>
|
|
|
|
|
</div>
|
|
|
|
|
<?php endforeach; ?>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- footer pas toucher -->
|
|
|
|
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/js/bootstrap.bundle.min.js" integrity="sha384-FKyoEForCGlyvwx9Hj09JcYn3nv7wiPVlz7YYwJrWVcXK/BmnVDxM+D2scQbITxI" crossorigin="anonymous"></script>
|
|
|
|
|
<script src="./styles-scripts/index.js"></script>
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|