Codice PHP:
$a 1;
while (
$row mysql_fetch_assoc($res)) { 
echo 
"<tr>";
echo 
"<td>".$row['name']."</td>";
echo 
"<td>".$row['number']."</td>";
echo 
"<td>$a</td>";
echo 
"</tr>";
$a++;