function initData()
{
//
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//           declare constants
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//  CONSTANTS
//  =========
  menuWait    = 250;                                // Mouse must hover menuWait milliseconds before submenu opens
  profWait    = 350;                                // Mouse must hover profWait millisecs before mini-profile opens

 // Durations (in millisec) for the display of each slide
  slowSlides  = 5000;                               // Longest
  medmSlides  = 3000;                               // Medium
  fastSlides  = 2000;                               // Shortest

  slideWait   = medmSlides;                         // Each slide in slideshow is displayed for slideWait millisecs
  frameRate   = 25;                                 // The number of images/second used in "zoom" transitions
  zoomDuration= 250;                                // The duration of "zoom" transitions in milliseconds
  zoomUpOnly  = true;                               // In slideshow transitions, no shrink-animation on departing slide
  zoomSteps   = 20;                                 // The number of repetitions of the same image at increasing sizes in "zoom"

  maxProfiles = 6;                                  // Number of mini profiles
  maxPicXY    = 600;                                // The larger side (x or y) of every enlargement is maxPicXY pixels 
  maxThmXY    = 192;                                // The larger side (x or y) of every thumbnail is maxThmXY pixels
  maxFlyH     = 550;                                // The tallest allowed fly-out text box.
  ttipOpacity = 0.9;                                // Tool-tip opacity (90%)
  ttipPersist = 120000;                             // Tool-tip fades after 2 minutes
  
  rowWide     = 575;                                // Space to be filled with thumbnails (in pixels)
  rowSpace    = 19;                                 // Spacing between thumbnails (in pixels)
  noOfAlbums  = 3;                                  // Number of thumbnail albums to be displayed on screen
  testTitles  = ['public','private','passkey','other'];
  albumTitle  = testTitles;                         // Array of album names (for test purposes)
  albSubtitle =  ['','','',''];                     // Array of album subtitles (for test purposes)

  preImg      = 'images/';                          // Prefix to image filenames
  preThumb    = 'thumbsG/Picture ';                 // Prefix to thumbnail name, indicating its physical location
  preLThmb    = 'largethumbsG/Picture ';            // Prefix to large thumbnail name, indicating its physical location
  preLarge    = 'largephotosG/Picture ';            // Prefix to large img name, indicating its physical location
  imgExtn     = '.jpg';                             // Images' filename extension

  btnGoTo     = 'images/textbuttons/go-to-page.png';// Image source of "go to page" button
  btnEmail    = 'images/textbuttons/email.png';     // Image source of "email" button
  btnIM       = 'images/textbuttons/im.png';        // Image source of "IM" button

  btnMore     = 'images/buttons/plus_base.png';
  btnLess     = 'images/buttons/minus_base.png';

  blankImg    = 'images/transparent.png';           // A single transparent pixel

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//           declare global variables
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//  TEXT
//  ====
  divId       = '';                                 // HTML <div> Id. For use in document.getElementById() commands
  currMenu    = '';                                 // Current menu selection
  currOpen    = '';                                 // Currently open menu
  currProf    = '';                                 // Currently selected mini-profile
  profileOwner= '';                                 // Currently selected mini-profile (newer code)
  profToHide  = '';                                 // Former mini-profile selection. Will be hidden from view.
  tnPicHTML   = '';                                 // Variable which takes dynamically-created HTML for thumbnail imagess
  tnCapHTML   = '';                                 // Variable which takes dynamically-created HTML for thumbnail captions

//  INDICATORS
//  ==========
  thumbSmall  = true;                               // Large or small thumbnails selected? (Small is default)
  bigPic      = true;                               // Does page have a "big pic"? (Yes is default)
  flyGlryOnVP = false;                              // Fly-out gallery displayed on viewport?

  macOS       = (navigator.userAgent.toLowerCase().indexOf("mac")!=-1) ? true: false;   // Is browser running on a Mac?
  IE          = document.all?true:false;            // Is browser IE?
  slideState  = '';                                 // Is slideshow running?
  zoomState   = '';                                 // Is a slide zooming?
  albumState  = ['many','one','one','one','one'];   // Each album... are several rows showing or just one?

//  DIMENSIONS & COORDINATES
//  ========================
  vPortWide   = 0;                                  // Width (in pixels) of the viewport
  vPortHigh   = 0;                                  // Height (in pixels) of the viewport
  oldVPWide   = -999;                               // Previous width (in pixels) of the viewport
  oldVPHigh   = -999;                               // Previous height (in pixels) of the viewport
  bigHigh     = 0;                                  // Height (in pixels) of the large image
  bigWide     = 0;                                  // Width (in pixels) of the large image
  maxHigh     = 0;                                  // Height (in pixels) of the highest large image
  maxWide     = 0;                                  // Width (in pixels) of the widest large image
  hRight      = 80;                                 // Distance (in pixels) from right edge of viewport to right edge of widest image
  hCntr       = 0;                                  // Distance (in pixels) from left edge of viewport to center of large image
  vCntr       = 0;                                  // Distance (in pixels) from top of viewport to center of large image
  scaleFactor = 0;                                  // Amount by which large image will be shrunk or stretched

  magnifyBy   = 0;                                  // Value (between 0 and 1) by which dimensions will be multiplied while zooming in and out

  mouseX      = 0;                                  // X-coordinate of mouse pointer (horizontal position, from left)
  mouseY      = 0;                                  // Y-coordinate of mouse pointer (vertical position, from top)
  linkZ       = 0;                                  // Z-index of link

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//  TIMERS
//  ======
  imgTimer    = null;                               // Timer used to ensure image load.
  slideTimer  = null;                               // Timer used in iterative function to run slideshow.

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//  INDICES
//  =======
  i           = 0;                                  // General purpose index. Significance depends on context.
  j           = 0;                                  // General purpose index. Significance depends on context.
  k           = 0;                                  // General purpose index. Significance depends on context.
  row         = 0;                                  // Index of thumbnail rows within page.
  cell        = 0;                                  // Index of thumbnail cells within row.
  startRow    = 0;                                  // Index of next thumbnail row to be loaded into page.
  endRow      = 0;                                  // Index of last thumbnail row to be loaded into page.
  zoomIx      = 0;                                  // Index used in "zoom" transitions.
  imgId   = 0;                                  // Index used in array of thumbnail IDs (for slideshow)

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//  DATA STRUCTURES
//  ===============
  currBig     = [0,0];                              // Array of [album-no, pic-no] used in big pic

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

  frameCnt    = Math.round((frameRate*zoomDuration)/1000);
  zoomAmts    = [];                                     // array of magnification factors used in zoom transitions
  zoomAmts[0] = 1/frameCnt;
  for (i=1; i < frameCnt; i++)                          // i = frame number
  {
    zoomAmts[i] = zoomAmts[(i-1)] + (1/frameCnt);
  }
  zoomAmts[(zoomAmts.length - 1)] = 1;

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
}

//                         ===================================
//                         end of constants & global variables
//                         ===================================
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
