currentIndx=0;

MyImages=new Array(10);

MyImages[0]='images/breastreduction/breastred1a.jpg';

MyImages[1]='images/breastreduction/breastred1b.jpg';

MyImages[2]='images/breastreduction/breastred2a.jpg';

MyImages[3]='images/breastreduction/breastred2b.jpg';

MyImages[4]='images/breastreduction/breastred3a.jpg';

MyImages[5]='images/breastreduction/breastred3b.jpg';

MyImages[6]='images/breastreduction/breastred4a.jpg';

MyImages[7]='images/breastreduction/breastred4b.jpg';

MyImages[8]='images/breastreduction/breastred5a.jpg';

MyImages[9]='images/breastreduction/breastred5b.jpg';




imagesPreloaded = new Array(10)

for (var i = 0; i < 10 ; i++)

{

imagesPreloaded[i] = new Image(568,307)

imagesPreloaded[i].src=MyImages[i]

}

function Nexter(){

if (currentIndx < 9){

/* the length of our array is 4. But the images go from 0 to 3, so we take one off the count. (We made currentIndx equal 0 right at the beginning of our script!) */

currentIndx=currentIndx+1;

/* To go forward, we add one, providing the number is less than the number of images */

document.theImage.src=imagesPreloaded[currentIndx].src

/* The NAME of the image in our slide show is theImage. We can change the image loaded here as above */

}

else {

currentIndx=9

/* Otherwise, we go back to the beginning, if currentIndx is too big */

document.theImage.src=imagesPreloaded[currentIndx].src

}

}

/* The function Baccker() is similar to the previous function, so it contains no comments */

function Backer(){

if (currentIndx>=0){

currentIndx=currentIndx-1;

document.theImage.src=imagesPreloaded[currentIndx].src

}

else {

currentIndx=0

document.theImage.src=imagesPreloaded[currentIndx].src

document.form1.text1.value=Messages[currentIndx];

}}

 