le code de ma page principale :
<?php
session_start();
mysql_connect("localhost","root","+ujk920") or die("error");
mysql_select_db(smash);
if($_GET[id]=="logout"){
session_destroy();
header(´Location:/smash´);
}
if($_GET[id]=="login2"){
if(empty($_POST[login])||empty($_POST[pass])){
header(´Location:?id=login´);
}
else{
$login=ucwords(strtolower(mysql_real_escape_string
($_POST[login])));
$pass=sha1(sha1(mysql_real_escape_string(($_POST[p
ass])).$login));
$verifi=mysql_query("select * from members where member=´$login´&&pass=´$pass´");
$verif=mysql_num_rows($verifi);
if($verif==1){
$_SESSION[login]=$login;
header(´Location:/smash´);
}
else{
header(´Location:?id=login&result=false´);
}
}
}
include(´func.php´);
?>
<title>__ S m a s h - S u p r e m e __ .:: Le PoRTaiL OnLine De SuPer SmAsH VeRsiOn PC !! ::.</title>
<link rel="stylesheet" href="css.css" type="text/css">
<div align=center>
<table width=830 cellspacing=0 cellpadding=0>
<tr>
<td valign="top" class="top" colspan="2">
</td>
</tr>
<tr>
<td valign="top" class="left">
<br><br>
<table cellspacing=0 cellpadding=0 width=100%>
<tr>
<td class="admin" valign="top">
<?php
if(empty($_SESSION[login])){
echo´<a href="?id=register"> Super Smash | Inscription </a>
<a href="?id=login">Super Smash | Identification </a>´;
}
if(isset($_SESSION[login])){
echo´
<a href="?id=logout">Super Smash | Deconnexion</a>
Super Smash | Mon compte
Super Smash | Administration´;
}
?>
</td>
</tr>
</table>
<br><br>
<table cellspacing=0 cellpadding=0 width=100%>
<tr>
<td class="menu" valign="top">
<strong>Le site</strong>
</td>
</tr>
<tr>
<td class="menu2" valign="top">
<br>
<a href=/smash/>Accueil</a><br>
Forum<br>
Super Smash | Affiliation<br>
Super Smash | Staff<br>
Super Smash | Plan Site<br>
<br>
<br>
<br>
</td>
</tr>
<tr>
<td class="menu" valign="top">
<strong>Informations</strong>
</td>
</tr>
<tr>
<td class="menu2" valign="top">
<br>
Super Smash | Qu´est ce que c´est ?< br>
Super Smash | Histoire<br>
Super Smash | Personnages<br>
Super Smash | Stadiums<br>
Super Smash | Objets<br>
<br>
<br>
<br>
</td>
</tr>
<tr>
<td class="menu" valign="top">
<strong>Goodies</strong>
</td>
</tr>
<tr>
<td class="menu2" valign="top">
<br>
Super Smash | Images<br>
Super Smash | Fan-Arts<br>
Super Smash | Wallpapers<br>
Super Smash | Screensavers<br>
<br>
<br>
<br>
</td>
</tr>
</table>
<br><br>
</td>
<td valign="top" class="right">
<br><br><br><br>
<?php
if(empty($_GET[id])){
$newss=mysql_query("select * from news order by id DESC");
while($news=mysql_fetch_array($newss)){
echo ´
<table cellspacing=0 cellpadding=0 width=100%>
<tr>
<td class="news" valign="top" colspan="2">
<strong>• Super Smash</strong> - ´.$news[titre].´
</td>
</tr>
<tr>
<td class="news2" valign="top">
<br>
´.y($news[value]).´
<br><br>
<td class="news3" valign="top">
<div align="center">
<img width=100 height=100 src=´.$news[member].´>
</div>
</td>
</td>
</tr>
<tr>
<td class="news" valign="top" colspan="2">
´.calctime($news[´date´]).´
</td>
</tr>
</table>´;
}
}
else{
if($_GET[id]=="register"){
if(file_exists(´register.php´)){
include(´register.php´);}
else{echo´<br>Erreur : Fichier manquant´;}
}
if($_GET[id]=="login"){
if(file_exists(´login.php´)){
include(´login.php´);}
else{echo´<br>Erreur : Fichier manquant´;}
}
}
?>
<br><br>
</td>
</tr>
<tr>
<td valign="top" class="bottom" colspan="2">
</td>
</tr>
</table>
</div>