// Script:   JavaScript SlideShow Script
// Function: Display images continuously in a slideshow
// =======================================
// Set speed (milliseconds)

var speed = 4000

// Specify the photo files

var Photo = new Array() 

// to add more images, continue the pattern, adding to the array below

Photo[0] = 'images/show/newsign.JPG'
Photo[1] = 'images/show/farming.JPG'
Photo[2] = 'images/show/xcbridge.jpg'
Photo[3] = 'images/show/July4.JPG'
Photo[4] = 'images/show/cong_church.JPG'
Photo[5] = 'images/show/scenic_road.JPG'
Photo[6] = 'images/show/BMDGrange_web.JPG'
Photo[7] = 'images/show/dawnFL.JPG'

//  

var t
var j = 0
var p = Photo.length

var preLoad = new Array()
for (i = 0; i < p; i++){
   preLoad[i] = new Image()
   preLoad[i].src = Photo[i]
}

function runSlideShow(){
   document.images.SlideShow.src = preLoad[j].src
   j = j + 1
   if (j > (p-1)) j=0
   t = setTimeout('runSlideShow()', speed)
}


