Пример #1
0
<?php

include 'class/requiert.php';
$authentification = new requiert();
$authentification->acces();
$authentification->admin();
?>
<!DOCTYPE html>
<html>
    <head>
	<link rel="stylesheet" type="text/css" href="css.css">
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Administration</title>
    </head>
    <body> 

<?php 
include 'menu.php';
?>
<br>
<h2>Administration</h2> 
		  
		<a class="boutonadmin" href="validation.php">Gèrer les revervations</a><br>
		<a class="boutonadmin" href="site.php">Gèrer les sites</a><br>
		<a class="boutonadmin" href="logement.php">Gèrer les logements</a><br>
		<a class="boutonadmin" href="semaine.php">Gèrer les vacances</a> <br>
		<a class="boutonadmin" href="droits.php">Gèrer les droits des utilisateurs</a><br>

	

	<br><br></div></div>
Пример #2
0
<?php

include 'class/requiert.php';
$authentification = new requiert();
$authentification->acces();
if (isset($_POST['up'])) {
    if (!empty($_POST['nom']) and !empty($_POST['prenom']) and !empty($_POST['email'])) {
        $_SESSION['user'] = htmlspecialchars($_POST['nom']);
        $_SESSION['prenom'] = htmlspecialchars($_POST['prenom']);
        $_SESSION['email'] = htmlspecialchars($_POST['email']);
        include_once 'class/update_user.php';
        $up = new update_user($_SESSION['id'], $_SESSION['user'], $_SESSION['prenom'], $_SESSION['email']);
        $up->req_update();
        $modif = true;
    }
}
include_once 'class/infos_user.php';
$infos = new infos_user($_SESSION['id']);
$infos->req_data();
$infos = $infos->get_data();
include_once 'header.php';
?>
 
<h2>Profil</h2><br />
	<?php 
echo "<p>Bienvenue " . $_SESSION['user'] . " " . $_SESSION['prenom'] . ",</p><br>";
?>

<?php 
if (isset($modif) and $modif == true) {
    echo '<p>Vos modifications ont été prises en compte.</p>';