maxImages=19;id1='imag1';id2='imag2';t=new Array();k=i=19;twoload=0;firststart=1;function randimg(){k=i;while(i==k){i=Math.floor(Math.random()*maxImages)+1}hiddenImg=new Image();if(i<10)hiddenImg.src='images/imag0'+i+'.jpg';else hiddenImg.src='images/imag'+i+'.jpg'}function smooth(){document.getElementById(id1).style.opacity=m/100;document.getElementById(id1).style.filter="alpha(opacity="+m+")";document.getElementById(id2).style.opacity=n/100;document.getElementById(id2).style.filter="alpha(opacity="+n+")";m+=2;n-=2;t[0]=setTimeout("smooth()",20);if(m>100)clearTimeout(t[0])}function change(){id3=id1;id1=id2;id2=id3;m=0;n=100;document.getElementById(id1).src=hiddenImg.src;smooth();randimg()}function itload(){if(twoload){if(firststart){randimg();firststart=0}setTimeout("change()",4000)}else twoload=1}

