var imagenes = new armarvector ("fotosCabecera/1.jpg", "fotosCabecera/2.jpg","fotosCabecera/3.jpg", "fotosCabecera/4.jpg", "fotosCabecera/5.jpg", "fotosCabecera/6.jpg");

function Imagen_Aleatoria() {
hoy= new Date();
maximo=6;
segundos=hoy.getSeconds();


if (segundos==0) {segundos=1}
	 while (segundos>maximo) {segundos=segundos-maximo}
	 document.write ('<IMG SRC="'+imagenes[segundos]+'" border=0>');
}


function armarvector (v1, v2,v3,v4,v5,v6) {
 this[1]=v1;
 this[2]=v2;
 this[3]=v3;
 this[4]=v4;
 this[5]=v5;
 this[6]=v6;
}

function fotoCambiante(foto)
{
  hoy= new Date();
  maximo=6;
  segundos=hoy.getSeconds();
  if(segundos==0)
  {
    segundos=1;
  }
	while(segundos>maximo)
  {
    segundos=segundos-maximo;
  }
  //alert(imagenes[segundos]);
  foto.src=imagenes[segundos];
}

//alert(document.getElementById("cambiante"));
fotoCambiante(document.getElementById("cambiante"));

