// JavaScript Document
<!--
var images = new Array();

images[0] = "i/pen_y_fan.jpg"; // URL to referance images>
images[1] = "i/biking.jpg";
images[2] = "i/caving_big.jpg";
images[3] = "i/canoeing.jpg";
images[4] = "i/climbing.jpg";
images[5] = "i/rafting.jpg";
images[6] = "i/fishing.jpg";


function ShowImg() {
var number = images.length;
var increment = Math.floor(Math.random() * number);
var strTemp ='<img src="' + images[increment] + '">';
document.write(strTemp);
}

var rotate = 5000; 
var count = 0;

function RotateImg(myImage){
 myImage.src=images[count];
 count++;
 if(count==images.length){count = 0;}
 setTimeout("RotateImg(myImage)",rotate);
} 



if (document.images)
{
/* preload the images */
homeoff = new Image();
homeoff.src = "i/logo.gif"
homeon = new Image();
homeon.src = "i/logo_f2.gif"
}

/* function to set image to on state */
function On(imageName)
{
 if (document.images)
   {
    document[imageName].src = eval(imageName+"on.src");
   }
}
	
	
/* function to reset image back to off state */
function Off(imageName)
{
 if (document.images)
   {
    document[imageName].src = eval(imageName+"off.src");
   }
}

//-->
