var g_u697c7f9e1b33c_img = document.getElementById("u697c7f9e1b33c_slideshowImg"); var g_u697c7f9e1b33c_i = 0; var last_u697c7f9e1b33c_i = 0; g_u697c7f9e1b33c_img.setAttribute("src",u697c7f9e1b33c_images[0]); function u697c7f9e1b33c_swap() { while (g_u697c7f9e1b33c_i == last_u697c7f9e1b33c_i) { if (g_u697c7f9e1b33c_random) g_u697c7f9e1b33c_i = Math.floor(Math.random() * (u697c7f9e1b33c_images.length-1)+.5); else { g_u697c7f9e1b33c_i++; if (g_u697c7f9e1b33c_i >= u697c7f9e1b33c_images.length) g_u697c7f9e1b33c_i = 0; } } last_u697c7f9e1b33c_i = g_u697c7f9e1b33c_i; g_u697c7f9e1b33c_img.setAttribute("src",u697c7f9e1b33c_images[g_u697c7f9e1b33c_i]); setTimeout("u697c7f9e1b33c_swap()",g_u697c7f9e1b33c_delay); } if (u697c7f9e1b33c_images.length > 1) { if (g_u697c7f9e1b33c_random) { u697c7f9e1b33c_swap() } else { setTimeout("u697c7f9e1b33c_swap()",g_u697c7f9e1b33c_delay); } }