function initPhoto() {
   this.length = 43 // File name, width, height
   this[0] = "Photos to randomize among"
   this[1] = "lighthouse.jpg/150/198/Lighthouse near Navy Pier, Chicago, IL"
   this[2] = "breeze.jpg/150/226/March Breeze"
   this[3] = "searstower.jpg/150/409/Sears Tower, Chicago, IL"
   this[4] = "dandelions.jpg/150/249/Controversial Beauty"
   this[5] = "polesky.jpg/150/276/Polescape"
   this[6] = "musevisits.jpg/150/226/Visit from the Muse"
   this[7] = "icyfalls.jpg/150/253/Starved Rock, Utica, IL"
   this[8] = "foxdam.jpg/150/226/Fox River, Illinois"
   this[9] = "sycamore.jpg/150/215/Winter Sycamore"
   this[10] = "snowytree.jpg/150/234/Winter's Burden"
   this[11] = "snowyrocks.jpg/150/239/Snowy Bluff at Starved Rock"
   this[12] = "grasses.gif/150/420/Every Blade Unique"
   this[13] = "whitepines.jpg/150/226/Black Limbs at White Pines State Park"
   this[14] = "newgrowth.jpg/150/286/New Growth"
   this[15] = "standingdeep.jpg/150/324/Standing Deep"
   this[16] = "treetangle.jpg/150/226/Tree Tangle under Blue Sky"
   this[17] = "blooming.jpg/150/203/Who can talk the flower out of blooming?"
   this[18] = "daffodils.jpg/150/249/Yellow without Shame"
   this[19] = "laketree.jpg/150/226/Tree-Cloud Meditation"
   this[20] = "pinkflower.jpg/150/215/Nameless Blooming"
   this[21] = "lyons.jpg/150/200/One of Many Paths"
   this[22] = "cloudmystic.jpg/150/226/Cloud Mystic"
   this[23] = "woodpath.jpg/150/216/Illinois Forest in June"
   this[24] = "grandstand.jpg/150/226/Empty Grandstand at Sunset"
   this[25] = "symmetry.jpg/150/226/Symmetry"
   this[26] = "bikebridge.jpg/150/216/Bicycle Path, Fox River"
   this[27] = "foxriverbridge.jpg/150/306/Stacked Fox River Bridge"
   this[28] = "illinoiscorn.jpg/150/226/Illinois Corn in August"
   this[29] = "mushrooms.jpg/150/241/Mushrooms on Wood Chips"
   this[30] = "silhouette.jpg/150/241/Silhouette"
   this[31] = "sunthrutree.jpg/150/241/Sun Dance"
   this[32] = "blisswoods2.jpg/150/226/Bliss Woods near Aurora, IL"
   this[33] = "fallupness.jpg/150/241/Fall Upness"
   this[34] = "warmthawaits.jpg/150/239/Warmth Awaits"
   this[35] = "unfallen.jpg/150/226/Unfallen"
   this[36] = "deciduous-coniferous.jpg/150/249/Deciduous and Coniferous"
   this[37] = "blisswoods.jpg/150/215/Bliss Woods"
   this[38] = "bashfulbeauty.jpg/150/226/Bashful Beauty"
   this[39] = "surviving.jpg/150/226/Survivors on Starved Rock"
   this[40] = "stop.jpg/150/383/A Word to the Wise"
   this[41] = "spruceribs.jpg/150/226/Spruce Ribs"
   this[42] = "3seasons.jpg/150/318/Three Seasons"
}
var Photo =  new initPhoto();
	
//Randomizing routine
function rand(n) {
seed = (0x015a4e35 * seed) % 0x7fffffff;
return ((seed >> 16) % n) + 1 ;
}
var now = new Date()
var seed = now.getTime() % 0xffffffff
var sub = (rand (42))
//sub = 38 
//Extract photo info from table
var photoInfo = Photo[sub];
var slash1 = photoInfo.indexOf("/",0);
var slash2 = photoInfo.indexOf("/", slash1 + 1);
var slash3 = photoInfo.indexOf("/", slash2 + 1);

var photoFilename = photoInfo.substring(0,slash1)
var photoWidth = photoInfo.substring(slash1+1, slash2);
var photoHeight = photoInfo.substring(slash2+1, slash3);
var photoCaption = photoInfo.substring(slash3+1, photoInfo.length);
//write HTML to show randomly selected photo
document.writeln("<center><IMG SRC='images/" + photoFilename + "' width='" + photoWidth + "' height='" + photoHeight + "' alt='" + photoCaption + "'border='0'><br><font face='verdana,arial,helvetica' size=1>" + photoCaption + "</font></center>");
