include ".../ascompainel/includes/conecta.inc";
$sqlLista = "select * from news order by nws_datahora desc limit 0, 6 ";
$execLista = mysql_query($sqlLista,$id);
$cn = 0;
while ($row = mysql_fetch_array($execLista, MYSQL_BOTH)) {
$row_lista['id'][$cn] = $row['nws_id'];
$row_lista['data'][$cn] = $row['nws_datahora'];
$row_lista['titulo'][$cn] = $row['nws_titulo'];
$row_lista['chamada'][$cn] = $row['nws_chamada'];
$cn++;
}
function mdata($dt){
return substr($dt, 8,2)."-".substr($dt, 5, 2)."-".substr($dt, 0, 4);
}
mysql_close($id);
?>