var speed = 7000;

function fade_image()
{
	if ($(this).next().length>0 /*&& $(this).next().get(0).nodeName=="IMG"*/)
		$(this).fadeOut(speed).next().fadeIn(speed, fade_image);
	else
	{
		$(this).fadeOut(speed);
		$("#header img.ImageElement:eq(0)").fadeIn(speed, fade_image);
	}
}

$(document).ready(function()
{
	if (/\/[0-9]+-[0-9]+\/preview.html/.test(window.location.href))
		$("#header img.ImageElement").show().parent().css("position", "relative");
	else $("#header img.ImageElement:eq(0)").show().fadeOut(speed).next().fadeIn(speed, fade_image);
});

