<th>Stat</th>
		<th>#1</th>
		<th>#2</th>
		<th>#3</th>
		<th>#4</th>
		<th>#5</th>
	</tr>';
foreach ($rankings as $key => $value) {
    #$template .= '#'.$key.'#'.$value.'+<br>';
    #$template .= $value['name'];
    $template .= '<tr><td>' . $value['name'] . '</td>';
    for ($i = 0; $i < 5; $i++) {
        $template .= '<td>
			<table width="200" border="0" cellspacing="0">
              <tr>
                <td rowspan="2"><img src="' . $ROOT . 'game-images/ranks/icon/rank_' . $value['data'][$i]['rank'] . '.gif" alt="' . getRankByID($value['data'][$i]['rank']) . '"></td>
                <td><a href="' . $ROOT . '?pid=' . $value['data'][$i]['id'] . '">' . $value['data'][$i]['name'] . '</a> </td>
                <td rowspan="2"><img src="' . $ROOT . 'game-images/flags/' . strtoupper($value['data'][$i]['country']) . '.png" alt="Country: ' . getCountryByCode($value['data'][$i]['country']) . '" width="16" height="12" /></td>
              </tr>
              <tr>
                <td>' . $value['data'][$i]['value'] . '</td>
              </tr>
            </table>
			</td>
			';
    }
    $template .= '</tr>		
		<tr class="separator"><td colspan="6">&nbsp;</td></tr>';
}
$template .= '	
	</tbody></table>
Example #2
0
			<td nowrap="nowrap">More Enemies<br />(Top 10)</td>
			<td>
';
if (count($enemies) < 10) {
    $limit = count($enemies) - 1;
} else {
    $limit = 9;
}
$written = 0;
for ($i = 1; $i <= $limit; $i++) {
    if ($enemies && trim($enemies[$i]['attacker']) != '' && $enemies[$i]['count'] > 1) {
        if ($written != 0) {
            $template .= ', ';
        }
        $written++;
        $template .= '<acronym title="his rank is ' . getRankByID(getRankFromPID($enemies[$i]['attacker'])) . '"><img src="' . $ROOT . 'game-images/ranks/icon/rank_' . getRankFromPID($enemies[$i]['attacker']) . '.gif"> <a rel="nofollow" href="?pid=' . $enemies[$i]['attacker'] . '">' . getNickFromPID($enemies[$i]['attacker']) . '</a></acronym> (' . $enemies[$i]['count'] . ')';
    }
}
$template .= '	
			</td>
		</tr>
		
	</table>
	
	<table border="0" cellpadding="0" cellspacing="0" id="misc" class="stat">
		<tr>
			<th colspan="2">Misc. Stats</th>

		</tr>
		<tr>
			<td>PID (Player ID Number)</td>