currentIndx=0;

MyImages=new Array(10);

MyImages[0]='images/tummytuck/tummytuck1a.jpg';

MyImages[1]='images/tummytuck/tummytuck1b.jpg';

MyImages[2]='images/tummytuck/tummytuck1c.jpg';

MyImages[3]='images/tummytuck/tummytuck1d.jpg';

MyImages[4]='images/tummytuck/tummytuck1e.jpg';

MyImages[5]='images/tummytuck/tummytuck2a.jpg';

MyImages[6]='images/tummytuck/tummytuck2b.jpg';

MyImages[7]='images/tummytuck/tummytuck2c.jpg';

MyImages[8]='images/tummytuck/tummytuck3a.jpg';

MyImages[9]='images/tummytuck/tummytuck3b.jpg';

MyImages[10]='images/tummytuck/tummytuck4a.jpg';

MyImages[11]='images/tummytuck/tummytuck4b.jpg';

MyImages[12]='images/tummytuck/tummytuck5a.jpg';

MyImages[13]='images/tummytuck/tummytuck5b.jpg';

MyImages[14]='images/tummytuck/tummytuck6a.jpg';

MyImages[15]='images/tummytuck/tummytuck6b.jpg';



imagesPreloaded = new Array(16)

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

{

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

imagesPreloaded[i].src=MyImages[i]

}

function Nexter(){

if (currentIndx < 15){

/* 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=15

/* 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];

}}

 