Ver Mensaje Individual
  #4 (permalink)  
Antiguo 13/02/2008, 12:26
Avatar de GatorV
GatorV
$this->role('moderador');
 
Fecha de Ingreso: mayo-2006
Ubicación: /home/ams/
Mensajes: 38.567
Antigüedad: 18 años
Puntos: 2135
Re: Problema con FOR

Código PHP:
$counter 1;
while ( 
row = array)
{
echo 
'
                                <tr width="342px" bgcolor="'
.row_color($i).'">
                                    <td align="center">'
.$counter.'&nbsp</td>
                                    <td align="center">'
.$row["nick"].'</td>
                                    <td align="center">'
.$row["nombre"].'</td>
                                    <td align="center">'
.$row["email"].'</td>                                    
                                    <td align="center">'
.$row["puntos"].'</td>
                                </tr>'
;
}
$counter++; 
No es necesario que hagas toda una consulta, simplemente pasale el numer que vas incrementando.

Saludos.