I have the following SQL
<?php
require_once("php/conexao.php");
$strSQL = "SELECT id, titulo FROM questoes ORDER by id DESC";
if($result = mysqli_query($conexao, $strSQL)) {
while($row = mysqli_fetch_assoc($result)) {
$ID = $row['id'];
$titulo = $row['titulo'];
}
}
?>
And the following table:
<div class="row tabela">
<div class="col-md-12">
<div class="panel panel-primary">
<div class="panel-heading">
<h3 class="panel-title">Lista de Questões</h3>
<div class="pull-right">
<span class="clickable filter" data-toggle="tooltip" title="Toggle table filter" data-container="body">
<i class="glyphicon glyphicon-filter"></i>
</span>
</div>
</div>
<div class="panel-body">
<input type="text" class="form-control" id="dev-table-filter" data-action="filter" data-filters="#dev-table" placeholder="Filter Developers" />
</div>
<table class="table table-hover" id="dev-table">
<thead>
<tr>
<th>ID</th>
<th>Título da Questão</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Exemplo</td>
</tr>
<tr>
<td>2</td>
<td>Exemplo</td>
</tr>
<tr>
<td>3</td>
<td>Exemplo</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
I'm trying to organize the "ID" and "title" data that I pull from SQL correctly in the table, but I'm pounding my head. It is a very beginner doubt, but I really am without a path, lol. I'm a beginner in PHP and SQL and it's my first system.