query(" SELECT hlstats_Clans.tag, hlstats_Clans.name, hlstats_Clans.homepage, hlstats_Clans.game, SUM(hlstats_Players.kills) AS kills, SUM(hlstats_Players.deaths) AS deaths, SUM(hlstats_Players.connection_time) AS connection_time, COUNT(hlstats_Players.playerId) AS nummembers, ROUND(AVG(hlstats_Players.skill)) AS avgskill, TRUNCATE(AVG(activity),2) as activity FROM hlstats_Clans LEFT JOIN hlstats_Players ON hlstats_Players.clan = hlstats_Clans.clanId WHERE hlstats_Clans.clanId=$clan AND hlstats_Players.hideranking = 0 GROUP BY hlstats_Clans.clanId "); if ($db->num_rows() != 1) error("No such clan '$clan'."); $clandata = $db->fetch_array(); $db->free_result(); $cl_name = preg_replace(' ', ' ', htmlspecialchars($clandata['name'])); $cl_tag = preg_replace(' ', ' ', htmlspecialchars($clandata['tag'])); $cl_full = "$cl_tag $cl_name"; $game = $clandata['game']; $db->query("SELECT name FROM hlstats_Games WHERE code='$game'"); if ($db->num_rows() != 1) $gamename = ucfirst($game); else list($gamename) = $db->fetch_row(); ?>
: | '.$clandata['name'].''; ?> | |
: | ||
: | ||
: | ||
: | 40) $bar_type = '6'; elseif ($clandata['activity'] > 30) $bar_type = '5'; elseif ($clandata['activity'] > 20) $bar_type = '4'; elseif ($clandata['activity'] > 10) $bar_type = '3'; elseif ($clandata['activity'] > 5) $bar_type = '2'; echo "'; ?> | |
: | ||
: | ||
: | ||
: |