jacek wrote:You would put them all into an array.
[syntax=php] while($row = mysql_fetch_array( $result ) ) {
$players[$row['id']] = $row;
}[/syntax]
Now using that how would I replace Player name with a each user from database
example of Bracket
[syntax=xhtml]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang='en'>
<head>
<meta http-equiv='Content-Type' content='text/html; charset=ISO-8859-1'>
<title>MY Tournament</title>
<!-- link rel='stylesheet' href='style.css' type='text/css' -->
<style type="text/css">
<!--
table {
border-collapse: collapse;
border: none;
font: small arial, helvetica, sans-serif;
}
td {
vertical-align: middle;
width: 10em;
margin: 0;
padding: 0;
}
td p {
border-bottom: solid 1px black;
margin: 0;
padding: 5px 5px 2px 5px;
}
-->
</style>
</head>
<body>
<table summary="Tournament Bracket">
<tr>
<td><p>1. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
<td rowspan="4"><p>Player name</p></td>
<td rowspan="8"><p>Player name</p></td>
<td rowspan="16"><p>Player name</p></td>
</tr>
<tr>
<td><p>16. Player name</p></td>
</tr>
<tr>
<td><p>8. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
</tr>
<tr>
<td><p>9. Player name</p></td>
</tr>
<tr>
<td><p>5. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
<td rowspan="4"><p>Player name</p></td>
</tr>
<tr>
<td><p>12. Player name</p></td>
</tr>
<tr>
<td><p>4. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
</tr>
<tr>
<td><p>13. Player name</p></td>
</tr>
<tr>
<td><p>6. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
<td rowspan="4"><p>Player name</p></td>
<td rowspan="8"><p>Player name</p></td>
</tr>
<tr>
<td><p>11. Player name</p></td>
</tr>
<tr>
<td><p>3. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
</tr>
<tr>
<td><p>14. Player name</p></td>
</tr>
<tr>
<td><p>7. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
<td rowspan="4"><p>Player name</p></td>
</tr>
<tr>
<td><p>10. Player name</p></td>
</tr>
<tr>
<td><p>2. Player name</p></td>
<td rowspan="2"><p>Player name</p></td>
</tr>
<tr>
<td><p>15. Player name</p></td>
</tr>
</table>
</body>
</html>[/syntax]