I am sorry, I know you guys hate when someone starts a new thread.
I have searched the forums and can't seem to find the answer. It is probably out there, but I just couldn't find it.
When I use the following code I get 50000000.00 while I am trying to get 50,000,000.00
//Select all members ordered by level (highest first, members table also doubles as rankings table)
$query = $db->execute("select `id`, `username`, `bank` from `players` order by `bank` desc limit 1000");
while($member = $query->fetchrow())
{
echo "<tr>\n";
echo "<td><a href=\"profile.php?id=" . $member['username'] . "\">";
echo ($member['username'] == $player->username)?"<b>":"";
echo $member['username'];
echo ($member['username'] == $player->username)?"</b>":"";
echo "</a></td>\n";
echo "<td>" . $member['bank'].number_format($number, 2, '.', ',')."</td>\n";
echo "</tr>\n";
}
I have also tried
//Select all members ordered by level (highest first, members table also doubles as rankings table)
$query = $db->execute("select `id`, `username`, `bank` from `players` order by `bank` desc limit 1000");
while($member = $query->fetchrow())
{
echo "<tr>\n";
echo "<td><a href=\"profile.php?id=" . $member['username'] . "\">";
echo ($member['username'] == $player->username)?"<b>":"";
echo $member['username'];
echo ($member['username'] == $player->username)?"</b>":"";
echo "</a></td>\n";
echo "<td>" . $member['bank'].number_format($number)."</td>\n";
echo "</tr>\n";
}
Which produces 5000000000
If anyone could tell me what I am doing wrong it would be greatly appreciated..