﻿var arrPics = new Array();
arrPics[0] = new Image();
arrPics[1] = new Image();
arrPics[2] = new Image();
arrPics[3] = new Image();
arrPics[4] = new Image();
arrPics[5] = new Image();
arrPics[6] = new Image();
arrPics[7] = new Image();
arrPics[8] = new Image();
arrPics[9] = new Image();
arrPics[10] = new Image();

arrPics[0].src = "images/pic0s.jpg";
arrPics[1].src = "images/pic1s.jpg";
arrPics[2].src = "images/pic2s.jpg";
arrPics[3].src = "images/pic3s.jpg";
arrPics[4].src = "images/pic4s.jpg";
arrPics[5].src = "images/pic5s.jpg";
arrPics[6].src = "images/pic6s.jpg";
arrPics[7].src = "images/pic7s.jpg";
arrPics[8].src = "images/pic8s.jpg";
arrPics[9].src = "images/pic9s.jpg";
arrPics[10].src = "images/pic10s.jpg";

var arrCaptions = new Array();
arrCaptions[0] = "April Violette judges Dennie Semore";
arrCaptions[1] = "Cindy Magdalany crossing the bridge";
arrCaptions[2] = "Kim Gallagher & Vickie Bell cutting up after the ride";
arrCaptions[3] = "Kori on Two Stripes; up for adoption";
arrCaptions[4] = "Linda Lambert and Toby going out to judge.";
arrCaptions[5] = "Michelle McKee and her granddaughter, Kayla collecting donations";
arrCaptions[6] = "Riders heading out";
arrCaptions[7] = "Safety Riders, Donna & Kori Gaskill on PER rescues";
arrCaptions[8] = "The Williams from Mobile, AL. ride out";
arrCaptions[9] = "Trish Manring; in good company";
arrCaptions[10] = "Two Stripes is ready to go!";

var arrLinks = new Array();
arrLinks[0] = "images/pic0.jpg";
arrLinks[1] = "images/pic1.jpg";
arrLinks[2] = "images/pic2.jpg";
arrLinks[3] = "images/pic3.jpg";
arrLinks[4] = "images/pic4.jpg";
arrLinks[5] = "images/pic5.jpg";
arrLinks[6] = "images/pic6.jpg";
arrLinks[7] = "images/pic7.jpg";
arrLinks[8] = "images/pic8.jpg";
arrLinks[9] = "images/pic9.jpg";
arrLinks[10] = "images/pic10.jpg";


var picNum=0;

function showPic()  //changes the picture
  {
  document.getElementById("links").href = arrLinks[picNum];
  document.getElementById("pics").src = arrPics[picNum].src;
  document.getElementById("caption").innerHTML = arrCaptions[picNum];

   if (picNum == 10)
    {
    picNum = 0;
    }
  else
    {
    picNum = picNum+1;
    } 
   var t1= setTimeout("showPic()",4000);  
  } 


