var timer=0; var maximgs =0; var indeximg = 1; var timer2=0; var maximgs2 =0; var indeximg2 = 1; function next_image() { var img = new Image; if (indeximg < maximgs) { indeximg++; } else indeximg=1; img = images[indeximg]; document.getElementById("animation").src = img; timer=setTimeout("next_image()",1500); } function next_image2() { var img2 = new Image; if (indeximg2 < maximgs2) { indeximg2++; } else indeximg2=1; img2 = images2[indeximg2]; document.getElementById("promotion").src = img2; timer2=setTimeout("next_image2()",100); } function anime_images($rub,$rep_mages,$taille,$logon) { var img = new Image; images = new Array(1); images[0+1] = "animation/images/LOGOACCUEIL.png"; maximgs = 1; indeximg = 1; timer=setTimeout("next_image()",10); }