コード例 #1
0
print "   <td width=\"60\" align=\"center\">Type</td>\n";
print "   <td width=\"60\" align=\"center\">Image</td>\n";
print "   <td width=\"60\" align=\"center\">Game</td>\n";
print " </tr>\n";
$high_i = 1;
$fetch_highest_scores = mysql_query("SELECT * FROM `web_scores` ORDER BY `score_score` {$fetch_sort} LIMIT 0, {$fetch_limit}") or die(mysql_error());
if (mysql_num_rows($fetch_highest_scores) == "0") {
    print "  <tr bgcolor=\"#ffffff\">\n";
    print "   <td colspan=\"40\" align=\"center\" class=\"small\">No data to display</td>\n";
    print " </tr>\n";
}
while ($fetch_high_row = mysql_fetch_assoc($fetch_highest_scores)) {
    foreach ($fetch_high_row as $key => $value) {
        ${$key} = $value;
    }
    $player_codename = return_codename($score_player);
    $high_game_type = strtoupper($score_game_type);
    $score_event_name = return_event_title($score_event);
    print "  <tr bgcolor=\"#ffffff\">\n";
    print "   <td align=\"center\">{$high_i}</td>\n";
    print "   <td><a href=\"./stats_player.php?playerId={$score_player}\">{$player_codename}</a></td>\n";
    print "   <td align=\"center\">{$score_rank}</td>\n";
    print "   <td align=\"center\">{$score_score}</td>\n";
    print "   <td align=\"center\">{$score_event_name}</td>\n";
    print "   <td align=\"center\">{$high_game_type}</td>\n";
    if ($fetch_high_row[score_scanned_image] != "") {
        print "   <td align=\"center\"><a href=\"./scanned/{$score_scanned_image}\" target=\"_blank\">View</a></td>\n";
    } else {
        print "   <td align=\"center\">-</td>\n";
    }
    print "   <td align=\"center\"><a href=\"./schedule.php?getEvent={$score_event}&getGame={$score_game}&getType={$score_game_type}\">View</a></td>\n";
コード例 #2
0
 print "   <td width=\"110\">Codename</td>\n";
 print "   <td width=\"60\" align=\"center\">Rank</td>\n";
 print "   <td width=\"60\" align=\"center\">Score</td>\n";
 print "   <td width=\"60\" align=\"center\">Type</td>\n";
 print "   <td width=\"60\" align=\"center\">Image</td>\n";
 print "   <td width=\"60\" align=\"center\">Game</td>\n";
 print " </tr>\n";
 $high_i = 1;
 $fetch_scores = mysql_query("SELECT * FROM `web_scores` WHERE score_event='{$eventId}' ORDER BY `score_score` {$fetch_sort} LIMIT 0, {$fetch_limit}");
 if (mysql_num_rows($fetch_scores) == "0") {
     print "  <tr bgcolor=\"#ffffff\">\n";
     print "   <td colspan=\"40\" align=\"center\" class=\"small\">No data to display</td>\n";
     print " </tr>\n";
 }
 while ($fetch_high_row = mysql_fetch_assoc($fetch_scores)) {
     $player_codename = return_codename($fetch_high_row[score_player]);
     $high_game_type = strtoupper($fetch_high_row[score_game_type]);
     print "  <tr bgcolor=\"#ffffff\">\n";
     print "   <td align=\"center\">{$high_i}</td>\n";
     print "   <td><a href=\"./stats_player.php?playerId={$fetch_high_row['score_player']}\">{$player_codename}</a></td>\n";
     print "   <td align=\"center\">{$fetch_high_row['score_rank']}</td>\n";
     print "   <td align=\"center\">{$fetch_high_row['score_score']}</td>\n";
     print "   <td align=\"center\">{$high_game_type}</td>\n";
     if ($fetch_high_row[score_scanned_image] != "") {
         print "   <td align=\"center\"><a href=\"./scanned/{$fetch_high_row['score_scanned_image']}\" target=\"_blank\">View</a></td>\n";
     } else {
         print "   <td align=\"center\">-</td>\n";
     }
     print "   <td align=\"center\"><a href=\"./schedule.php?getEvent={$eventId}&getGame={$fetch_high_row['score_game']}&getType={$fetch_high_row['score_game_type']}\">View</a></td>\n";
     print " </tr>\n";
     $high_i++;
コード例 #3
0
 }
 print "<table width=\"300\" cellspacing=\"1\" cellpadding=\"2\" class=\"table_bl_top\" align=\"center\">\n";
 print "  <tr>\n";
 print "   <td><b>Results</b></td>\n";
 print " </tr>\n";
 print "</table>\n\n";
 $color1 = "#ffffff";
 $color2 = "#f0f0f0";
 $row_count = 0;
 print "<table width=\"300\" cellspacing=\"1\" cellpadding=\"0\" bgcolor=\"#aaaaaa\" align=\"center\">\n";
 //if($compare_type == "overall")
 //    {
 print "  <tr>\n";
 print "   <td bgcolor=\"#ffffff\">&nbsp;</td>\n";
 foreach ($compare_array as $compare_key => $compare_player) {
     $player_codename = return_codename($compare_player);
     print "   <td bgcolor=\"#ffffff\" align=\"center\">&nbsp; {$player_codename}</td>\n";
 }
 print " </tr>\n";
 foreach ($col_array as $col_key => $col_title) {
     $row_color = $row_count % 2 ? $color1 : $color2;
     print "  <tr>\n";
     print "   <td bgcolor=\"{$row_color}\">&nbsp; {$col_title}</td>\n";
     foreach ($compare_array as $compare_key => $compare_player) {
         $array_count = count($array_overall[$compare_player][$col_key]);
         if ($array_count != "0") {
             $array_sum = array_sum($array_overall[$compare_player][$col_key]);
             $col_avg = round($array_sum / $array_count, 1);
             print "   <td bgcolor=\"{$row_color}\" align=\"center\">{$col_avg}</td>\n";
         } else {
             print "   <td bgcolor=\"{$row_color}\" align=\"center\">-</td>\n";
コード例 #4
0
 print "\t   <td width=\"30\" align=\"center\" class=\"small\">Rk</td>\n";
 print "\t   <td width=\"30\" align=\"center\" class=\"small\">Twr</td>\n";
 print "\t   <td width=\"45\" align=\"center\" class=\"small\">Score</td>\n";
 print "\t   <td width=\"35\" align=\"center\" class=\"small\">Img</td>\n";
 print "\t </tr>\n";
 $fetch_scores = mysql_query("SELECT * FROM `web_scores` WHERE score_event='{$getEvent}' AND score_team='{$set_team}' AND score_game='{$getGame}' ORDER BY `score_rank` ASC");
 if (mysql_num_rows($fetch_scores) == "0") {
     print "\t  <tr bgcolor=\"#ffffff\">\n";
     print "\t   <td colspan=\"5\" align=\"center\">Scores not available</td>\n";
     print "\t </tr>\n";
 }
 while ($scoreRow = mysql_fetch_assoc($fetch_scores)) {
     $score_score = $scoreRow[score_score];
     $score_deduc = $scoreRow[score_deduc];
     $score_scanned_image = $scoreRow[score_scanned_image];
     $field_player = return_codename($scoreRow[score_player]);
     if ($_GET["highlightPlayer"] != "" && is_numeric($_GET["highlightPlayer"])) {
         if ($_GET["highlightPlayer"] == $scoreRow[score_player]) {
             $playerRowBg = "#ffc4fd";
         } else {
             $playerRowBg = "#ffffff";
         }
     } else {
         $playerRowBg = "#ffffff";
     }
     print "\t  <tr bgcolor=\"{$playerRowBg}\">\n";
     $fetch_alias = mysql_query("SELECT * FROM `web_alias` WHERE player_id='{$scoreRow['score_player']}' AND alias_team='{$set_team}'");
     if (mysql_num_rows($fetch_alias) == "0") {
         print "\t   <td><a href=\"./stats_player.php?playerId={$scoreRow['score_player']}\">{$field_player}</a></td>\n";
     } else {
         $aliasRow = mysql_fetch_assoc($fetch_alias);