/*
Random image slideshow- By Tyler Clarke (tyler@ihatecoffee.com)
For this script and more, visit http://www.javascriptkit.com
*/

var delay=3500 //set delay in miliseconds
var curindex=0

var randomimages_lev=new Array()
	randomimages_lev[0]="ambient.gif"
	randomimages_lev[1]="cedar.gif"
	randomimages_lev[2]="hhb.gif"
	randomimages_lev[3]="inovonics.gif"
	randomimages_lev[4]="microtech.gif"
	randomimages_lev[5]="prodys.gif"
	randomimages_lev[6]="sonifex.gif"
	randomimages_lev[7]="sounddevices.gif"
	randomimages_lev[8]="vt.gif"
	randomimages_lev[9]="zaxcom.gif"	
	randomimages_lev[10]="eela.gif"	
	randomimages_lev[11]="lawo.gif"	
	randomimages_lev[12]="kelsey.gif"	
	randomimages_lev[13]="caps.gif"		
var preload=new Array()

for (n=0;n<randomimages_lev.length;n++)
{
	preload[n]=new Image()
	preload[n].src=randomimages_lev[n]
}

document.write('<img name="defaultimage_lev" src="'+randomimages_lev[Math.floor(Math.random()*(randomimages_lev.length))]+'"width="400" height="75" border="0" alt="Producenter">')

function rotateimage_lev()
{
	if (curindex==(tempindex=Math.floor(Math.random()*(randomimages_lev.length))))
	{
		curindex=curindex==0? 1 : curindex-1
	}
	else
	curindex=tempindex
	document.images.defaultimage_lev.src=randomimages_lev[curindex]
}

setInterval("rotateimage_lev()",delay)
