var theImages = new Array();
var theURLs = new Array();

// To add more image files, continue with the
// pattern below, adding to the array.

theImages[0] = 'images/royce_banner/custom_design.jpg';
theURLs[0] = 'http://www.royceayr.com/';

theImages[1] = 'images/royce_banner/hawk_pcd.jpg';
theURLs[1] = 'http://www.royceayr.com/';

theImages[2] = 'images/royce_banner/joinery.jpg';
theURLs[2] = 'http://www.royceayr.com/';

theImages[3] = 'images/royce_banner/kinkelder.jpg';
theURLs[3] = 'http://www.royceayr.com/';

theImages[4] = 'images/royce_banner/modern_tooling.jpg';
theURLs[4] = 'http://www.royceayr.com/';

theImages[5] = 'images/royce_banner/precision_custom_a.jpg';
theURLs[5] = 'http://www.royceayr.com/';

theImages[6] = 'images/royce_banner/precision_custom_b.jpg';
theURLs[6] = 'http://www.royceayr.com/';

theImages[7] = 'images/royce_banner/precision_holders.jpg';
theURLs[7] = 'http://www.royceayr.com/';

theImages[8] = 'images/royce_banner/shaping.jpg';
theURLs[8] = 'http://www.royceayr.com/';

theImages[9] = 'images/royce_banner/ultimate_combo.jpg';
theURLs[9] = 'http://www.royceayr.com/';


// do not edit anything below this line

//var j = 0;
var p = theImages.length;
var preBuffer = new Array();
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImages[i]
}
	var prevImage = 'x';
	var whichImage = 'x';
	function showImage(){
		while (whichImage==prevImage) {
		      whichImage = Math.round(Math.random()*(p));
		}
		prevImage=whichImage;
		document.write('<a href="' + theURLs[whichImage] + '" target="new"><img src="'+theImages[whichImage]+'" border="0"></a>');
	}