Ver Mensaje Individual
  #11 (permalink)  
Antiguo 17/04/2006, 20:16
chuanma
 
Fecha de Ingreso: noviembre-2005
Mensajes: 3
Antigüedad: 20 años, 10 meses
Puntos: 0
Código PHP:
<?php
define
( "NUM_ROW", 4 );

print 
"<table>";
$i = 0;
while( 
$row = mysql_fetch_array( $result ) )
{  
    print 
"<td>" . $row['valor'] . "</td>";
    
$i++;
    
    if( 
$i % NUM_ROW == 0 ) 
        print 
"</tr><tr>";
}  
print 
"</table>"  
?>
Espero esto te sirva y sea lo que buscabas, la constante NUM_ROW es el numero de columnas que tendras.