// JavaScript Document
function LinkShow(slideList, linkList, image, alink, speed, name)          
{
  this.slideList = slideList;
  this.linkList = linkList;
  this.image = image;
	this.alink = alink;
  this.speed = speed;
  this.name = name;
  this.current = 0;
  this.timer = 0;
}
LinkShow.prototype.play = LinkShow_play;  
function LinkShow_play()       
{
  with(this)
  {
    if(current++ == slideList.length-1) current = 0;

		var i = document.getElementById(image);
		i.src = slideList[current];

		var a = document.getElementById(alink);
		a.href = linkList[current];

    clearTimeout(timer);
    timer = setTimeout(name+'.play()', speed);
  }
}

