// ////////////////////////////////////
// change the image of the productsites

// beginn changing pictures
var stop = false;
// start with picture number ...
var bildnr = 1;
// how much picture you got ..

// set the layer visible and hidden
function        showLayer(name,state)
{
        if (client.isNS6)
                eval("document.getElementById('" + name + "').style.visibility='"+(state?'visible':'hidden')+"'");
        else
                eval("document."+(client.isIE?"all":"layers")+"."+name+(client.isIE?".style":"")+".visibility='"+(state?'visible':'hidden')+"'");
}

// compatibility method
function changeimage ()
{
 loopVarImages();
}

function startstop ()
{
		stop = !stop;
        if ( !stop )
                changeimage();
}

function loopVarImages(x) {
		var maxbildnr = x;
		if(!stop) {
            showLayer('vis'+bildnr+'Layer',true);
            for ( var j = 1 ; j <= maxbildnr ; ++j )
                  showLayer('vis'+j+'Layer',j==bildnr);
			bildnr = 1+(bildnr%maxbildnr);
            setTimeout('loopVarImages('+maxbildnr+');',2400);
         } else {
           clearTimeout();
         }

}
