Código: Seleccionar todo
<script language="javascript" type="text/javascript">
noticiero=new Array();
<? while($row=mysql_fetch_array($consulta))
{
?>
noticia("<?=$row['pathFotoNoticia'];?>","<?=$row['titulo'];?>","<?=$row['pathNoticia'];?>","<?=$row['link'];?>");
<?
}
?>
espera=2 //Segundos de espera
function noticia(imagen,titulo,texto,enlace)
{
this.imagen=imagen; this.texto=texto; this.titulo=titulo; this.enlace=enlace;
}
function mostrar_campo(id_campo)
{
return document.getElementById(id_campo);
}
function mostrar(a)
{
mostrar_campo("imagen_noticia").src=noticiero[a].imagen; mostrar_campo("titulo_noticia").innerHTML=noticiero[a].titulo; mostrar_campo("texto_noticia").innerHTML=noticiero[a].texto; mostrar_campo("enlace").href=noticiero[a].enlace;
}
b=0;
function cambiar()
{
if (b<noticiero.length)
{
b++;
}
else
{
b=0;
}
mostrar(b);
}
// Cada "espera*1000" milisegundos
// cambia a la siguiente noticia
setInterval("cambiar()",espera*1000);
</script>

Espero que me puedan ayudar, muchas gracias desde ya!!