////////////////////////////////////////////////////////////////
// Javascript made by Rasmus - http://www.peters1.dk //
////////////////////////////////////////////////////////////////

var SLIDE_path = 'http://www.techcompserv.com/JanRogers/images/coffeetables/'; // Path to the folder, where the images are put.

var SLIDE_text = new Array();
SLIDE_text[1] = 'My first painted coffee table, depicting a Jaguar and jungle scene.';
SLIDE_text[2] = 'This shot shows off the painting on the base and legs of the Jag table';
SLIDE_text[3] = 'This was my third painted table, and depicts a mama Armadillo and her four identical babies. I adore Armadillos.';
SLIDE_text[4] = 'This antique table is so special and lovely with its intricate carving, and beautiful legs- it looks like it was hand made.';
SLIDE_text[5] = 'This was my second painted table, a scene of Indian Elephants in a mountain meadow at sunset. I love elephants.';
SLIDE_text[6] = 'This shot shows off the bright red table legs and the pretty carving on the frame of the tabletop. Another beautiful vintage table.';
SLIDE_text[7] = 'This is my fourth painted table-- a small table with pretty french style legs, with a dot painting of a gecko on top, suitable for a child.';
SLIDE_text[8] = 'This shot shows the top of the Gecko table.';
// Don't change anything under here...

var SLIDE_pic = new Array();
var SLIDE_load = new Array();
var SLIDE_status, SLIDE_timeout;
var SLIDE_actual = 1;
var SLIDE_speed = 3000;
var SLIDE_fade = 2;

for (i = 1; i <= SLIDE_text.length-1; i++)
{
  SLIDE_pic[i] = SLIDE_path+i+'.jpg';
  SLIDE_load[i] = new Image();
  SLIDE_load[i].src = SLIDE_pic[i];
}
var SLIDE_count = SLIDE_pic.length-1;

function SLIDE_start()
{
  document.getElementById('SLIDE_pause').disabled = true;
  document.images.SLIDE_picBox.src = SLIDE_load[SLIDE_actual].src;
  document.getElementById("SLIDE_textBox").innerHTML= SLIDE_text[SLIDE_actual];
}

function SLIDE_play()
{
  document.getElementById('SLIDE_play').disabled = true;
  document.getElementById('SLIDE_pause').disabled = false;
  SLIDE_actual++;
  SLIDE_slide();
  SLIDE_status = 'SLIDE_play';
  SLIDE_timeout = setTimeout("SLIDE_play()",SLIDE_speed);
}

function SLIDE_pause()
{
  clearTimeout(SLIDE_timeout);
  SLIDE_status = 'SLIDE_pause';
  document.getElementById('SLIDE_pause').disabled = true;
  document.getElementById('SLIDE_play').disabled = false;	
}

function SLIDE_back()
{
  clearTimeout(SLIDE_timeout);
  SLIDE_actual--;
  SLIDE_slide();
  if (SLIDE_status != 'SLIDE_pause') SLIDE_timeout = setTimeout("SLIDE_play()",SLIDE_speed);
}

function SLIDE_forward()
{
  clearTimeout(SLIDE_timeout);
  SLIDE_actual++;
  SLIDE_slide()
  if (SLIDE_status != 'SLIDE_pause') SLIDE_timeout = setTimeout("SLIDE_play()",SLIDE_speed);
}


function SLIDE_slide()
{
  if (SLIDE_status != 'SLIDE_pause')
  {
    document.getElementById('SLIDE_play').disabled = true;
    document.getElementById('SLIDE_pause').disabled = false;
  }
  if (SLIDE_actual > (SLIDE_count)) SLIDE_actual=1;
  if (SLIDE_actual < 1) SLIDE_actual = SLIDE_count;
  if (document.all)
  {
    document.getElementById("SLIDE_textBox").style.background = "transparent";
    document.images.SLIDE_picBox.style.filter="blendTrans(duration=2)";
    document.images.SLIDE_picBox.style.filter="blendTrans(duration=SLIDE_fade)";
    document.images.SLIDE_picBox.filters.blendTrans.Apply();
  }
  document.images.SLIDE_picBox.src = SLIDE_load[SLIDE_actual].src;
  if (document.getElementById) document.getElementById("SLIDE_textBox").innerHTML= SLIDE_text[SLIDE_actual];
  if (document.getElementById) document.getElementById("SLIDE_count").innerHTML= SLIDE_actual;
  if (document.all) document.images.SLIDE_picBox.filters.blendTrans.Play();
}

function SLIDE_speeds(SLIDE_valgt)
{
  SLIDE_speed = SLIDE_valgt.options[SLIDE_valgt.selectedIndex].value;
}