/*
 * +---------------------------------
 * |
 * |   display a random Photograph
 * |
 * +---------------------------------
 */

var datenow      = new Date() ;
var datenowvalue = datenow.getTime() ;
var modulus = Math.floor(datenowvalue / photoArray.length) ;
var photoIndex = datenowvalue - (modulus * photoArray.length) ;

document.writeln("<div id=photo1>") ;

if (tablePhotoFilename[photoIndex] != " ")
   {
   var displayheight = tablePhotoHeight[photoIndex] ;
   var displaywidth  = tablePhotoWidth[photoIndex] ;
   if (displaywidth != maxPhotoWidth)
      {
      displayheight = displayheight * (maxPhotoWidth / displaywidth) ;
      displayheight = Math.floor(displayheight) ;
      displaywidth  = maxPhotoWidth ;
      } ;
   document.writeln("<img src=\"" + tablePhotoFilename[photoIndex] + "\" height=" + displayheight + " width=" + displaywidth + ">") ;
   } ;

