var theTopImg = new Array() // do not change this
// To add more image files, continue with the
// pattern below, adding to the array.

theTopImg[0] = 'imgs/rotating/top1.jpg';
theTopImg[1] = 'imgs/rotating/top2.jpg';
theTopImg[2] = 'imgs/rotating/top3.jpg';

// do not edit anything below this line

var j = 0
var p = theTopImg.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image();
   preBuffer[i].src = theTopImg[i];
}
var whichImg = Math.round(Math.random()*(p-1));
function showTopImage(){
document.write('<img src="'+theTopImg[whichImg]+'">');
}

//  End -->




var theImg = new Array() // do not change this
// To add more image files, continue with the
// pattern below, adding to the array.

theImg[0] = 'imgs/rotating/left1.jpg'
theImg[1] = 'imgs/rotating/left2.jpg'
theImg[2] = 'imgs/rotating/left3.jpg'

// do not edit anything below this line

var j = 0
var p = theImg.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImg[i]
}
var whichImg = Math.round(Math.random()*(p-1));
function showLeftImage(){
document.write('<div class="rotimg"><img src="'+theImg[whichImg]+'"></div>');
}

//  End -->

// JavaScript Document-Faculity1

var current = 0;

var myPics = new Array();
function addTAPic(_p) {
  myPics[myPics.length?myPics.length:0] = new Image();
  myPics[myPics.length-1].src=_p;// preload all pics
}

addTAPic("imgs/facilities/TA03.jpg");
addTAPic("imgs/facilities/TA04.jpg");
addTAPic("imgs/facilities/TA05.jpg");

function checkIt1(val) {
  current = Math.abs((current+parseInt(val))%myPics.length);
  document.myimg.src = myPics[current].src;
}

function showTApics(){
document.write("<img name=myimg border=0 alt='Academy for Teaching, Learning and Leadership' src='"+myPics[current].src+"'>");
var myTimer1 = setInterval('checkIt1(1)',3000);// 3 second interval;
}

//End