1
I’m doing a database listing screen and showing the results in an HTML table, it’s all working, but I would like to limit the number of lines displayed by five to stay all on the same screen and the scrolling is done in the table itself. Follows the code:
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Nome</th>
<th>E_mail</th>
<th>Tipo</th>
<th>Opções</th>
</thead>
<tbody>
<?php while($reg=$listar->fetch_array()){
echo "<tr>";
echo "<td>".$reg['id_usuario']."</td>
<td>".$reg['nome_professor']."</td>
<td>".$reg['nome_usuario']."</td>
<td>".$reg['tipo']."</td>
<td>
<a class='btn btn-primary' name='deletar'><i class='fa fa-fw fa-lg fa-times-circle-o text-danger'></i></a>
</td>
<td><a class='btn btn-primary'><i class='fa fa-edit fa-fw fa-lg'></i></a> </td>";
"</tr>";
}
?>
</tbody>
</table>
A simple alternative would be to add the content inside an iframe, limit its size and place the scrollbar inside it
– MarceloBoni