Hey guys, which way is it better to list bank records? The first is the structured way and the second is the object oriented is not it? Thanks.
First:
$sql = $usuario -> listar();
foreach($sql AS $registro)
{
echo $registro['nome'];
}
Second:
$sql = $usuario -> listar();
foreach($sql AS $registro)
{
$usuario -> setNome($registro['nome']);
echo $usuario -> getNome();
}