function swapPhoto(theCaption1,theCaption2,theCaption3,theCaption4,theCaption5) {

var displayedCaption1 = document.getElementById("caption1");
displayedCaption1.firstChild.nodeValue = theCaption1;

var displayedCaption2 = document.getElementById("caption2");
displayedCaption2.firstChild.nodeValue = theCaption2;

var displayedCaption3 = document.getElementById("caption3");
displayedCaption3.firstChild.nodeValue = theCaption3;

var displayedCaption4 = document.getElementById("caption4");
displayedCaption4.firstChild.nodeValue = theCaption4;

var displayedCaption5 = document.getElementById("caption5");
displayedCaption5.firstChild.nodeValue = theCaption5;

}