Signed-off-by: Gregory PLANCHAT <g.planchat@gmail.com>

This commit is contained in:
Gregory PLANCHAT 2011-06-28 13:02:55 +02:00
commit 3fd8832b45
138 changed files with 2597 additions and 1253 deletions

View file

@ -44,7 +44,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$AllActivPlanet = doquery("SELECT * FROM {{table}} WHERE `last_update` >= '". (time()-15 * 60) ."' ORDER BY `id` ASC", 'planets');
$Count = 0;
while ($ActivPlanet = mysql_fetch_array($AllActivPlanet)) {
while ($ActivPlanet = $AllActivPlanet->fetch(PDO::FETCH_BOTH)) {
$parse['online_list'] .= "<tr>";
$parse['online_list'] .= "<td class=b><center><b>". $ActivPlanet['name'] ."</b></center></td>";
$parse['online_list'] .= "<td class=b><center><b>[". $ActivPlanet['galaxy'] .":". $ActivPlanet['system'] .":". $ActivPlanet['planet'] ."]</b></center></td>";

View file

@ -48,7 +48,7 @@ $parse = $lang;
// Affichage des messages
$query = doquery("SELECT * FROM {{table}} ORDER BY messageid DESC LIMIT 25", 'chat');
$i = 0;
while ($e = mysql_fetch_array($query)) {
while ($e = $query->fetch(PDO::FETCH_BOTH)) {
$i++;
$parse['msg_list'] .= stripslashes("<tr><th class=b>" . date('h:i:s', $e['timestamp']) . "</th>".
"<th class=b>". $e['user'] . "</th>".

View file

@ -49,7 +49,7 @@ $parse = $lang;
// Afficher les erreurs
$query = doquery("SELECT * FROM {{table}}", 'errors');
$i = 0;
while ($u = mysql_fetch_array($query)) {
while ($u = $query->fetch(PDO::FETCH_BOTH)) {
$i++;
$parse['errors_list'] .= "
<tr><td width=\"25\" class=n>". $u['error_id'] ."</td>

View file

@ -123,7 +123,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$StartRec = 1 + (($ViewPage - 1) * 25);
$Messages = doquery("SELECT * FROM {{table}} WHERE `message_type` = '". $Selected ."' ORDER BY `message_time` DESC LIMIT ". $StartRec .",25;", 'messages');
while ($row = mysql_fetch_assoc($Messages)) {
while ($row = $Messages->fetch(PDO::FETCH_ASSOC)) {
$OwnerData = doquery ("SELECT `username` FROM {{table}} WHERE `id` = '". $row['message_owner'] ."';", 'users',true);
$bloc['mlst_id'] = $row['message_id'];
$bloc['mlst_from'] = $row['message_from'];

View file

@ -57,7 +57,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$From = "<font color=\"". $kolor ."\">". $ranga ." ".$user['username']."</font>";
$Subject = "<font color=\"". $kolor ."\">". $gameConfig['temat'] ."</font>";
$Message = "<font color=\"". $kolor ."\"><b>". $gameConfig['tresc'] ."</b></font>";
while ($u = mysql_fetch_array($sq)) {
while ($u = $sq->fetch(PDO::FETCH_BOTH)) {
SendSimpleMessage ( $u['id'], $user['id'], $Time, 97, $From, $Subject, $Message);
}
message("<font color=\"lime\">Wys<79>a<EFBFBD>e<EFBFBD> wiadomo<6D><6F> do wszystkich graczy</font>", "Complete", "../overview." . PHPEXT, 3);

View file

@ -38,7 +38,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$parse = $lang;
$query = doquery("SELECT * FROM {{table}} WHERE planet_type='3'", "planets");
$i = 0;
while ($u = mysql_fetch_array($query)) {
while ($u = $query->fetch(PDO::FETCH_BOTH)) {
$parse['moon'] .= "<tr>"
. "<td class=b><center><b>" . $u[0] . "</center></b></td>"
. "<td class=b><center><b>" . $u[1] . "</center></b></td>"

View file

@ -45,7 +45,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$RowsTPL = gettemplate('admin/multi_rows');
$PageTPL = gettemplate('admin/multi_body');
while ($infos = mysql_fetch_assoc($query)) {
while ($infos = $query->fetch(PDO::FETCH_ASSOC)) {
$Bloc['player'] = $infos['player'];
$Bloc['text'] = $infos['text'];

View file

@ -38,7 +38,7 @@ require_once dirname(dirname(__FILE__)) .'/common.php';
$parse = $lang;
$query = doquery("SELECT * FROM {{table}} WHERE planet_type='1'", "planets");
$i = 0;
while ($u = mysql_fetch_array($query)) {
while ($u = $query->fetch(PDO::FETCH_BOTH)) {
$parse['planetes'] .= "<tr>"
. "<td class=b><center><b>" . $u[0] . "</center></b></td>"
. "<td class=b><center><b>" . $u[1] . "</center></b></td>"

View file

@ -47,7 +47,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
$GameUsers = doquery("SELECT * FROM {{table}} WHERE authlevel<3", 'users');
while ($CurUser = mysql_fetch_assoc($GameUsers)) {
while ($CurUser = $GameUsers->fetch(PDO::FETCH_ASSOC)) {
// Recuperation des anciennes statistiques
$OldStatRecord = doquery ("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `id_owner` = '".$CurUser['id']."';",'statpoints');
if ($OldStatRecord) {
@ -190,7 +190,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
// Statistiques des alliances ...
$GameAllys = doquery("SELECT * FROM {{table}}", 'alliance');
while ($CurAlly = mysql_fetch_assoc($GameAllys)) {
while ($CurAlly = $GameAllys->fetch(PDO::FETCH_ASSOC)) {
// Recuperation des anciennes statistiques
$OldStatRecord = doquery ("SELECT * FROM {{table}} WHERE `stat_type` = '2' AND `id_owner` = '".$CurAlly['id']."';",'statpoints');
if ($OldStatRecord) {