var pic_width=556;
var pic_height=720;
var button_text="Next Image";

if (document.images)
{
pic1= new Image(pic_width,pic_height);
pic1.src="images/performance-contract-1.jpg";  
pic2= new Image(pic_width,pic_height); 
pic2.src="images/performance-contract-2.jpg"; 
}    

var pics= new Array(2) 
pics[0]=pic1.src;
pics[1]=pic2.src;

var numpics=2;
var thenum=0;
imgName="img1";

function change_it()
{
if (document.images)
{
document.write("<img onClick='change_it2()' src='"+pics[thenum]+"'style='float:none;width:"+pic_width+"px;height:"+pic_height+"px;margin:0;padding:0;border:0 none;' alt='Mechanical Services Performance Contract.' name='img1' />\n");
}}

function change_it2()
{
var x=0;
thenum+=1;

if (thenum>numpics-1)
{ 
document[imgName].src=pics[0];
thenum=0;
}
else
{
document[imgName].src=pics[thenum];
x+=1;
}}