
//script for internal rotating images
var imagearray = new Array('../images/industryHeaders/r1.jpg','../images/industryHeaders/r2.jpg','../images/industryHeaders/r3.jpg','../images/industryHeaders/r4.jpg','../images/industryHeaders/r5.jpg','../images/industryHeaders/r6.jpg');
var j = 0
var p = imagearray.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = imagearray[i]
}
var whichImage = Math.round(Math.random()*(p-1));
function showImage(){
document.write('<img src="'+imagearray[whichImage]+'" width="597" height="219" alt="Resource Development Council" border="0">');
}

//script for pop up windows
function NewWindow(mypage, myname, w, h, tool, scroll) {
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',toolbar='+tool+',scrollbars='+scroll+',resizable'
	win = window.open(mypage, myname, winprops)
	if (parseInt(navigator.appVersion) >= 4) { 
		win.window.focus(); 
	}
}

//captions for the rotating image

//captions for the rotating image
var frontcaptions = new Array("EPA Administrator Mike Leavitt spoke at this years Annual Meeting","RDC Breakfasts are held the first and third Thursdays from September to May at the Petroleum Club of Anchorage.","RDC members Mine A Cookie in support of AMEREF, the Alaska Mineral and Energy Resource Education Fund.","RDC Board members and staff participated in RDCs annual community outreach trip this year to Valdez. Shown, President Shively drives an Alyeska Pipeline SERVS tug in Prince William Sound.");
//TOTAL number of images for rotating image
var numfront = 4;
//don't mess with the next line
var whichfront = Math.round(Math.random()*(numfront-1));

//function that displays the image and text for the rotating image
function frontrotate(){
document.write('<img src="images/front'+whichfront+'.jpg" alt="'+frontcaptions[whichfront]+'" border="1"><br><img src="images/spacer.gif" width="3" height="3" alt=" "><br>'+frontcaptions[whichfront]);
}

