if($account->isBanned())
{
if(is_int($number_of_rows / 2)) { $bgcolor = $config['site']['darkborder']; } else { $bgcolor = $config['site']['lightborder']; } $number_of_rows++;
$main_content .= '<TR BGCOLOR="'.$bgcolor.'"><TD><font color=red>Banished:</font></TD>';
$ban_reason = array("Offensive Name", "Invalid Name Format", "Unsuitable Name", "Name Inciting Rule Violation", "Offensive Statement", "Spamming", "Illegal Advertising", "Off-Topic Public Statement", "Non-English Public Statement", "Inciting Rule Violation", "Bug Abuse", "Game Weakness Abuse", "Using Unofficial Software to Play", "Hacking", "Multi-Clienting", "Account Trading or Sharing", "Threatening Gamemaster", "Pretending to Have Influence on Rule Enforcer", "False Report to Gamemaster", "Destructive Behaviour", "Excessive Unjustified Player Killing", "Invalid Payment", "Spoiling Auction");
$players_banned = $SQL->query('SELECT `expires`, `added`, `reason` FROM `bans` WHERE `value` = '.$account.' AND `active` = 1 GROUP BY `value` ORDER BY `added` DESC')->fetchAll();
foreach($players_banned as $player)
{
if ($player['expires'] == "-1") // If the banishment is permanent
$expires = "Permament";
else
$expires = date("j F Y, g:i a", $player['expires']);
$player_ban .= '<font color=red>At '.date("j F Y, g:i a", $player['added']).' CET because of '.$ban_reason[$player['reason']].'. Expires at '.$expires.' CET</font>';
}
$main_content .= '<td>'.$player_ban.'</td></tr>';
}
$main_content .= '</TABLE>';