HB/pages/depart.php

84 lines
2.4 KiB
PHP
Raw Normal View History

2007-10-27 10:00:00 +00:00
<?php
2007-11-03 11:00:00 +00:00
session_start();
2007-03-31 10:00:00 +00:00
$id=$_SESSION['id'];
$galaxy=$_SESSION['galaxy'];
$ss=$_SESSION['ss'];
$pos=$_SESSION['pos'];
2007-11-03 11:00:00 +00:00
$race=$_SESSION['race'];
2007-03-31 10:00:00 +00:00
2007-11-03 11:00:00 +00:00
echo"<html>
<head>
<title>Space battleship</title>
<link rel=stylesheet media=screen type=text/css title=design href=descriptions/diz/base.css >
<meta http-equiv=pragma content=no-cache >
<meta http-equiv=content-type content=text/html;charset=iso-8869-1 >
<link rel=shortcut icon type=image/x-icon href=favicon.ico >
2007-03-31 10:00:00 +00:00
2007-11-03 11:00:00 +00:00
<style TYPE=text/css>
TD.c {
background-color: black;
}
2007-03-31 10:00:00 +00:00
2007-11-03 11:00:00 +00:00
TD.d {
background-color: #000043;
2007-03-31 10:00:00 +00:00
}
2007-11-03 11:00:00 +00:00
#img {
margin-left: 100;
padding: 10 50 10 50;
border: 0;
background-color: #000043;
}
</style>";
include 'bdd.php';
include 'ressource.php';
$case = $cases - ($mine_m +$mine_c +$mine_h +$centrale_s +$centrale_f +$radar+$labo+$chantier_terrestre +$chantier_spatial+$caserne+$silo );
$diametre = $cases * 92;
2007-10-27 10:00:00 +00:00
require('../connectBDD.php');
2007-03-31 10:00:00 +00:00
$nbr = mysql_query("SELECT COUNT(*) AS nbre FROM mail WHERE destinataire='".$pseudo."' AND vu='1'");
$nbre_non = mysql_fetch_assoc($nbr);
2007-11-03 11:00:00 +00:00
2007-10-27 10:00:00 +00:00
$ee = mysql_query("SELECT pseudo, points, place_points FROM user WHERE id='".$id."'");
2007-03-31 10:00:00 +00:00
$data = mysql_fetch_array($ee);
2007-11-03 11:00:00 +00:00
function convert_ts_fr($tstamp) { echo date('H:i:s d/m/Y', $tstamp); }
echo"</head>
2007-10-27 10:00:00 +00:00
<body>
2007-11-03 11:00:00 +00:00
<table width=500 align=center>
<tr><td colspan=2 align=left class=c>Ev<EFBFBD>nements</td></tr>
<tr><td witdh=50 class=d>Heure du serveur</td>
<td>"; convert_ts_fr(time()); echo"</td></tr>";
if ($nbre_non['nbre'] == 1) { echo "<tr><td colspan=2><a href=lire_message.php>Vous avez 1 nouveau message</a></td></tr>"; }
else if ($nbre_non['nbre'] > 1) {echo "<tr><td colspan=2><a href=lire_message.php>Vous avez ".$nbre_non['nbre']." nouveaux messages</a></td></tr>"; }
2007-10-27 10:00:00 +00:00
echo "<tr><td colspan=2 align=left class=c><a href=rename.php>".$nom_planete."</a> (".$data['pseudo'].")</td></tr>
2007-11-03 11:00:00 +00:00
<tr><td align=center colspan=2 height=220><div id=img><img src='descriptions/diz/planete/".$image.".jpg' height=200 width=200></div></td></tr>
<tr><td witdh=50 class=d>Diam<EFBFBD>tre</td>
2007-10-27 10:00:00 +00:00
<td>".$diametre." km ( ".$case." / ".$cases." cases )</td></tr>
2007-11-03 11:00:00 +00:00
<tr><td witdh=50 class=d>Race</td>
<td>".$race."</td></tr>
<tr><td witdh=50 class=d>Position</td>
<td><a href=carte.php?galaxy=".$galaxy."&ss=".$ss.">[".$galaxy.":".$ss.":".$pos."]</a></td></tr>
<tr><td witdh=50 class=d>Classement</td>
2007-10-27 10:00:00 +00:00
<td><a href=voir_classement.php >".$data['points']." points (".$data['place_points'].")</a></td></tr>
2007-11-03 11:00:00 +00:00
</table>
</body></html>"; ?>