Updated page display
Updated signature image generator Navigation menu has been finalized Some deprectaed templates has been removed Fixed registration Fixed galaxy notices messages Signed-off-by: Gregory PLANCHAT <g.planchat@gmail.com>
This commit is contained in:
parent
ec7e40e1aa
commit
6d61e93c47
67 changed files with 10177 additions and 940 deletions
|
|
@ -42,14 +42,14 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$StatDate = time();
|
||||
// Rotation des statistiques
|
||||
doquery ( "DELETE FROM {{table}} WHERE `stat_code` = '2';" , 'statpoints');
|
||||
doquery ( "DELETE FROM {{table}} WHERE `stat_code` >= '10';" , 'statpoints');
|
||||
doquery ( "UPDATE {{table}} SET `stat_code` = `stat_code` + '1';" , 'statpoints');
|
||||
|
||||
$GameUsers = doquery("SELECT * FROM {{table}} WHERE authlevel<3", 'users');
|
||||
|
||||
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');
|
||||
$OldStatRecord = doquery ("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `id_owner` = '".$CurUser['id']."';", 'statpoints', true);
|
||||
if ($OldStatRecord) {
|
||||
$OldTotalRank = $OldStatRecord['total_rank'];
|
||||
$OldTechRank = $OldStatRecord['tech_rank'];
|
||||
|
|
@ -81,7 +81,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
$GCount = $TTechCount;
|
||||
$GPoints = $TTechPoints;
|
||||
$UsrPlanets = doquery("SELECT * FROM {{table}} WHERE `id_owner` = '". $CurUser['id'] ."';", 'planets');
|
||||
while ($CurPlanet = mysql_fetch_assoc($UsrPlanets) ) {
|
||||
while ($CurPlanet = $UsrPlanets->fetch(PDO::FETCH_ASSOC)) {
|
||||
$Points = GetBuildPoints ( $CurPlanet );
|
||||
$TBuildCount += $Points['BuildCount'];
|
||||
$GCount += $Points['BuildCount'];
|
||||
|
|
@ -134,7 +134,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$Rank = 1;
|
||||
$RankQry = doquery("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `stat_code` = '1' ORDER BY `tech_points` DESC;", 'statpoints');
|
||||
while ($TheRank = mysql_fetch_assoc($RankQry) ) {
|
||||
while ($TheRank = $RankQry->fetch(PDO::FETCH_ASSOC)) {
|
||||
$QryUpdateStats = "UPDATE {{table}} SET ";
|
||||
$QryUpdateStats .= "`tech_rank` = '". $Rank ."' ";
|
||||
$QryUpdateStats .= "WHERE ";
|
||||
|
|
@ -145,7 +145,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$Rank = 1;
|
||||
$RankQry = doquery("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `stat_code` = '1' ORDER BY `build_points` DESC;", 'statpoints');
|
||||
while ($TheRank = mysql_fetch_assoc($RankQry) ) {
|
||||
while ($TheRank = $RankQry->fetch(PDO::FETCH_ASSOC) ) {
|
||||
$QryUpdateStats = "UPDATE {{table}} SET ";
|
||||
$QryUpdateStats .= "`build_rank` = '". $Rank ."' ";
|
||||
$QryUpdateStats .= "WHERE ";
|
||||
|
|
@ -156,7 +156,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$Rank = 1;
|
||||
$RankQry = doquery("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `stat_code` = '1' ORDER BY `defs_points` DESC;", 'statpoints');
|
||||
while ($TheRank = mysql_fetch_assoc($RankQry) ) {
|
||||
while ($TheRank = $RankQry->fetch(PDO::FETCH_ASSOC)) {
|
||||
$QryUpdateStats = "UPDATE {{table}} SET ";
|
||||
$QryUpdateStats .= "`defs_rank` = '". $Rank ."' ";
|
||||
$QryUpdateStats .= "WHERE ";
|
||||
|
|
@ -167,7 +167,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$Rank = 1;
|
||||
$RankQry = doquery("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `stat_code` = '1' ORDER BY `fleet_points` DESC;", 'statpoints');
|
||||
while ($TheRank = mysql_fetch_assoc($RankQry) ) {
|
||||
while ($TheRank = $RankQry->fetch(PDO::FETCH_ASSOC)) {
|
||||
$QryUpdateStats = "UPDATE {{table}} SET ";
|
||||
$QryUpdateStats .= "`fleet_rank` = '". $Rank ."' ";
|
||||
$QryUpdateStats .= "WHERE ";
|
||||
|
|
@ -178,7 +178,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
$Rank = 1;
|
||||
$RankQry = doquery("SELECT * FROM {{table}} WHERE `stat_type` = '1' AND `stat_code` = '1' ORDER BY `total_points` DESC;", 'statpoints');
|
||||
while ($TheRank = mysql_fetch_assoc($RankQry) ) {
|
||||
while ($TheRank = $RankQry->fetch(PDO::FETCH_ASSOC)) {
|
||||
$QryUpdateStats = "UPDATE {{table}} SET ";
|
||||
$QryUpdateStats .= "`total_rank` = '". $Rank ."' ";
|
||||
$QryUpdateStats .= "WHERE ";
|
||||
|
|
@ -192,7 +192,7 @@ if (strtolower(substr(PHP_SAPI, 0, 3)) == 'cli' || in_array($user['authlevel'],
|
|||
|
||||
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');
|
||||
$OldStatRecord = doquery ("SELECT * FROM {{table}} WHERE `stat_type` = '2' AND `id_owner` = '".$CurAlly['id']."';",'statpoints', true);
|
||||
if ($OldStatRecord) {
|
||||
$OldTotalRank = $OldStatRecord['total_rank'];
|
||||
$OldTechRank = $OldStatRecord['tech_rank'];
|
||||
|
|
|
|||
Loading…
Reference in a new issue