//
// Front end JavaScript include file - this should be included on the front end.
//

var imageID = 2; // set this to be the second image you want on screen (the first is the actual <img>)
var numberOfImages = 4;

function fetchImage(){ 
	debug('fetchImage called with - imageID: '+imageID);
	requestString = '/returnimage.php?mode=getnextimage&imageid='+imageID;
	sendRequest(requestString);
	if (imageID==(numberOfImages)){
		imageID = 1;
	}
	else{
		imageID++;
	}
}

