Ver Mensaje Individual
  #4 (permalink)  
Antiguo 22/05/2017, 10:33
Avatar de Briss
Briss
 
Fecha de Ingreso: junio-2011
Mensajes: 1.293
Antigüedad: 12 años, 10 meses
Puntos: 12
Respuesta: duplicar encabezado en tabla por número de registros

Tengo el total de registros si es mayor a 0 dibujo la tabla, no se me ocurre como volver a dibujar la tabla si es que el total es mayor a 25


Código PHP:
$query_docentes = "SELECT * FROM docentes ";
$docentes = mysql_query($query_docentes, $connection) or die(mysql_error());
$row_docentes = mysql_fetch_assoc($docentes);
$tdocentes= mysql_num_rows($docentes);

<?php if ($tdocentes ) { ?>
<table>
  <thead>
    <tr>
      <td>USUARIO</td>
      <td>Nombre</td>
      <td>A. paterno</td>
      <td>A. Materno</td>
      <td>Email</td>


   
    </tr></thead>
  <?php do { ?>
    <tbody>
      <tr>   
     
          <td><?php echo $row_docentes['Clave']; ?></td>
          <td><?php echo $row_docentes['Nombre']; ?></div></td>
          <td><?php echo $row_docentes['ApellidoPaterno']; ?></div></td>
          <td><?php echo $row_docentes['ApellidoMaterno']; ?></div></td>
          <td><?php echo $row_docentes['Email']; ?></div></td>
        
      </tr></tbody>
    <?php } while ($row_docentesmysql_fetch_assoc($docentes)); ?>
</table>

  <?php // Fin de $tdocentes ?>