$sqld = "SELECT CodNoticia, titulo, Imagem, data, Categoria FROM Turismo_noticias where Destaque = '2' ORDER BY Data DESC LIMIT 3";
$srd = mysqli_query($conexao, $sqld);
$total_registrosd = mysqli_num_rows($srd);
foreach ($srd as $row) {
$lnd[] = [
'CodNoticia' => $row['CodNoticia'],
'titulo' => $row['titulo'],
'Imagem' => $row['Imagem'],
'data' => $row['data'],
'Categoria' => $row['Categoria']
];
}
$remove = "";
if($total_registrosd == 3){
?>
$remove = 'AND CodNoticia NOT IN('. $lnd[0]['CodNoticia'] .','. $lnd[1]['CodNoticia'] .','. $lnd[2]['CodNoticia'] .')';
}
?>
Galeria
Mais Imagens
Loading...