// JavaScript Document
//random_images.js
//random image rotator for Katzen site by matt {@} mattbillings.com


// Create arrays to contain all the values 
// for image locations

image_array = new Array
var image_index = 0;

image_array[image_index++]="images/rotating/ac_entrance.jpg"
image_array[image_index++]="images/rotating/hallway.jpg"
image_array[image_index++]="images/rotating/museum1.jpg"
image_array[image_index++]="images/rotating/outside_window.jpg"
image_array[image_index++]="images/rotating/window.jpg"
image_array[image_index++]="images/rotating/museum2.jpg"
image_array[image_index++]="images/rotating/outside1.jpg"
image_array[image_index++]="images/rotating/outside2.jpg"
image_array[image_index++]="images/rotating/outside3.jpg"




// quote array is associtated to the image array
// make sure quote[x] is the caption for image_arraay[x] 

quote = new Array
var quote_index = 0;

quote[quote_index++] = "Academic Entrance";
quote[quote_index++] = "Katzen Hallway";
quote[quote_index++] = "AU Museum and Sculpture Garden";
quote[quote_index++] = "AU Museum Window";
quote[quote_index++] = "Katzen Upper Plaza from Museum";
quote[quote_index++] = "AU Museum Gallery";
quote[quote_index++] = "Katzen Plaza toward Rotunda";
quote[quote_index++] = "Katzen Plaza toward Museum";
quote[quote_index++] = "Katzen Plaza Cascade";



// Create a random number between 1 and length of quote array
random_num = (Math.round(Math.random()*(quote_index-1)))
//alert(random_num_quote);


// returns image tag with approrpite alt_tag and image name
function get_image(){
return("<img class=\"side_img\" src=\""  + image_array[random_num] + "\" name=\"left_image\" alt=\""+ quote[random_num] +"\" />");
}

// returns quote corresponding to the image called above
function get_quote(){
	return quote[random_num];
}

