I have a question about design pattern in php.
I have a class DAO
that has a selection method, well what happens is that I had to put some stylized HTML codes with bootstrap in this method, what did I do this correct?
class CategoriaDao {
public function selecionaTudo($sql) {
$conexao = new PDOUtil();
$consulta = $conexao->conectar()->query($sql);
while ($sqlSeleciona = $consulta->fetch(PDO::FETCH_OBJ)){
echo "<td>" . $sqlSeleciona->descricao . "</td>";
echo '<td><a href="index.php?action=update&id='.$sqlSeleciona->id_categoria_pagina.'" class="btn btn-default btn-sm"><span class="glyphicon glyphicon-edit"></span> Editar</a></td>';
echo '<td><a href="index.php?action=delete&id='.$sqlSeleciona->id_categoria_pagina.'" class="btn btn-default btn-sm"><span class="glyphicon glyphicon-remove"></span> Excluir</a></td>';
echo "</tr>";
}
}