1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84
| <?php
session_start();
if(isset($_GET['deconnexion']) && $_GET['deconnexion']=="1"){
unset($_SESSION['idproprietaire']);
unset($_SESSION['utilisateur']);
session_destroy();
}
//pour tester
var_dump($_SESSION);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Le site de Fred</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="description" content="por mes dvd">
<meta name="keywords" content="dvd">
<META NAME="Author" LANG="fr" CONTENT="Philippe Fontayne">
<meta name="Robots" content="index, follow, all">
<META NAME="Revisit-after" CONTENT="5 days">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
<link rel="stylesheet" type="text/css" href="style.css">
</HEAD>
<BODY>
<div class="haut">
<TABLE WIDTH=100% BORDER="0" CELLPADDING="0" CELLSPACING="0">
<TR style="height:45px">
<TD align='center' width='87%'>
<font size='5' color='blue' face='Palatino'><B>LE SITE DE FRED</b></font><br>
</TD>
<TD align='center' width='13%' valign='middle'>
<font size='2' color='black' face='tahoma'>
<?php if (isset($_SESSION['utilisateur'])) { echo $_SESSION['utilisateur'];
echo "<br><a href=index.php?deconnexion=1>déconnecter</a></font><br>"; } ?>
</TD>
</TR>
</TABLE>
<?php
function date_fran() {
$mois = array("janvier", "fevrier", "mars", "avril", "mai", "juin", "juillet", "aout", "septembre", "octobre", "novembre", "decembre");
$jours = array("Dimanche", "Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi");
return $jours[date("w")]." ".date("j").(date("j") == 1 ? "er" : " "). $mois[date("n")-1]." ".date("Y")." - ".date("H")."h".date("i");
}
?>
<TABLE WIDTH=100% BORDER="1" class="bordure" style="border-color: white; FILTER:
progid:DXImageTransform.Microsoft.GRADIENT(startColorstr=#003366
,endColorstr=#ffffff ,gradientType=0" bgColor=#ffffff scroll=yes;>
<TR style="height:30px; color=white">
<TD WIDTH=23%><font face=verdana size=1><? echo (date_fran());?>
<TD WIDTH=15% class=td1>
<A HREF="index.php?page=accueil" class=td1><font color="white" style="text-decoration:none">accueil</A>
</TD>
<TD WIDTH=15% class=td1>
<A HREF="index.php?page=videotheq" class=td1><font color="white" style="text-decoration:none">Vidéothèque</A>
</TD>
<TD WIDTH=15% class=td1>
<A HREF="index.php?page=encours"><font color="white" style="text-decoration:none">Ce qui me manque</A>
</TD>
<TD WIDTH=15% class=td1>
<A HREF="index.php?page=ajout_film"><font color="white" style="text-decoration:none">Ajouter un film</A>
</TD>
</TR>
</TABLE>
</div>
<div class="conteneur">
<div class="frame">
<?php
if (!isset($_GET['page'])) $page= 'accueil'; else $page= $_GET['page'];
switch($page)
{
//menu horizontal
case 'accueil': include ('accueil.php');break;
case 'videotheq': include ('liste_films.php');break;
case 'ajout_film': include ('ajout_film.php');break;
case 'fiche_film': include ('fiche_film.php');break;
//autres sélections
case 'liste_films': include ('liste_films.php');break;
case 'film_modif': include ('film_modif.php');break;
}
?>
</div>
</div>
</body>
</html> |
Partager