//*********************************************
// Define the MultiDimensional Glossary Array *
// glossary[x][0] = "Word";                   *
// glossary[x][1] = "Definition";             *
// Note: html tags <strong>can</strong> be    * 
// entered in the definition as needed        *
//Array demension must be one greater than the last entry
//*********************************************
var glossary = new MultiDimensionalArray(43,2);
glossary[0][0] = "amphibian";
glossary[0][1] = "Cold-blooded animals with backbones. They live on both land and in water, lack scales, and produce external jello-like eggs requiring moist conditions. Montana is home to breeding populations of almost 15 amphibian species.";
glossary[1][0] = "bird";
glossary[1][1] = "A warm-blooded animal with a backbone. Birds are covered with feathers and produce external eggs. Montana is home to breeding populations of over 250 bird species. In addition, over 170 bird species visit our state during the spring and fall migration periods.";
glossary[2][0] = "CFWCS";
glossary[2][1] = "Comprehensive Fish &amp; Wildlife Conservation Strategy";
glossary[3][0] = "collaboration";
glossary[3][1] = "Working with and cooperating with others.";
glossary[4][0] = "community";
glossary[4][1] = "All of the populations of living organisms that occupy a defined area.";
glossary[5][0] = "crayfish";
glossary[5][1] = "Freshwater crustaceans resembling small lobsters.";
glossary[6][0] = "deciduous";
glossary[6][1] = "Refers to trees and shrubs that loose their leaves each year.";
glossary[7][0] = "ecosystem";
glossary[7][1] = "An ecosystem is a natural system consisting of all plants, animals, and microorganisms in an area functioning together with all the non-living physical elements of the environment. One can designate an ecosystem that is as small as a pond or as large as an entire nation.";
glossary[8][0] = "elevation";
glossary[8][1] = "The height (of a geographic location) above sea level.";
glossary[9][0] = "encompass";
glossary[9][1] = "To include comprehensively.";
glossary[10][0] = "big game";
glossary[10][1] = "Large animals that are hunted (Antelope, black bear, grizzly bear, deer, moose, mountain lion, mountain goat, bighorn sheep, elk).";
glossary[11][0] = "conifer";
glossary[11][1] = "Cone-bearing seed woody plants (most are trees, some are shrubs).";
glossary[12][0] = "FAS";
glossary[12][1] = "Fishing Access Site";
glossary[13][0] = "fish";
glossary[13][1] = "Aquatic vertebrates that are cold-blooded, covered with scales, and have two sets of paired fins and several unpaired fins.";
glossary[14][0] = "Fishing Access Site";
glossary[14][1] = "A Fish, Wildlife &amp; Parks property that is open to the public to fish on and launch boats.";
glossary[15][0] = "focus area";
glossary[15][1] = "Geographic starting points for Fish, Wildlife &amp; Parks to focus on conserving Montana's community types and species in greatest need of conservation.";
glossary[16][0] = "glacial";
glossary[16][1] = "Refers to large, slow moving rivers of ice, formed from compacted layers of snow, that slowly deform and flow in response to gravity.";
glossary[17][0] = "invertebrate";
glossary[17][1] = "An organism with no internal backbone.";
glossary[18][0] = "mammal";
glossary[18][1] = "A warm-blooded animal that is covered with hair and feeds its young milk produced from mammary glands. Montana is home to over 110 species.";
glossary[19][0] = "moraine";
glossary[19][1] = "An area of debris deposited by glaciers.";
glossary[20][0] = "mussel";
glossary[20][1] = "An invertebrate organism encased in two attached shells (bivalves).";
glossary[21][0] = "pectination";
glossary[21][1] = "Something with parallel toothlike projections, like a comb.";
glossary[22][0] = "reptile";
glossary[22][1] = "A cold-blooded animal, with a backbone and covered with scaly dry skin. External eggs are produced with a membrane and yolk sac. 17 native reptile species are native to Montana.";
glossary[23][0] = "riparian";
glossary[23][1] = "An area where water loving plants are found along streams and rivers.";
glossary[24][0] = "subalpine";
glossary[24][1] = "Refers to the habitat immediately below tree line.";
glossary[25][0] = "tectonic";
glossary[25][1] = "A field of study dealing with the structures, forces, and movements within the crust of the Earth.";
glossary[26][0] = "tier one species";
glossary[26][1] = "Refers to animals in the greatest need of conservation.";
glossary[27][0] = "topography";
glossary[27][1] = "The study of the elevation of the land.";
glossary[28][0] = "tree line";
glossary[28][1] = "The elevation at which trees are no longer capable of growing.";
glossary[28][0] = "understory plants";
glossary[28][1] = "The plants in a forest which grow in the shade of the tall trees.";
glossary[30][0] = "vernal pools";
glossary[30][1] = "Temporary pools of water.";
glossary[31][0] = "vertebrate";
glossary[31][1] = "An organism with an internal backbone.";
glossary[32][0] = "wetland";
glossary[32][1] = "An enviornment that has a wet and spongy soil, as a marsh, swamp, or bog.";
glossary[33][0] = "Wildlife Management Area";
glossary[33][1] = "A Fish, Wildlife &amp; Parks property that maintains vital wildlife habitat for the protection of species and the enjoyment of the public.";
glossary[34][0] = "WMA";
glossary[34][1] = "Wildlife Management Area";
glossary[35][0] = "horizons";
glossary[35][1] = "";
glossary[36][0] = "barble";
glossary[36][1] = "A thread like growth used by fish to help locate things through touch (example: the whiskers on a catfish).";
glossary[37][0] = "species diversity";
glossary[37][1] = "Refers to the number of different kinds of animals or plants found in an area.";
glossary[38][0] = "steward";
glossary[38][1] = "To be a steward of our natural resources is to help manage them wisely.";
glossary[39][0] = "FWP";
glossary[39][1] = "Fish, Wildlife &amp; Parks";
glossary[40][0] = "terrestrial";
glossary[40][1] = "Plants and animals that live on the land.";
glossary[41][0] = "forage";
glossary[41][1] = "Seeking out food.";
glossary[42][0] = "ungulate";
glossary[42][1] = "A hooved mammal.";

//***********************************************************
// This function will loop through the MultiDimensional     *
// Array to find the definition for the given glossary word *
//***********************************************************
function findDefinition(arrayObject, word)
{
  var _definition = "", _word = "";

  for (var i = 0; i < glossary.length; i++)
  {
    // compare lower case strings and return definition
    if (arrayObject[i][0].toLowerCase() == word.toLowerCase())
    {
        _word = arrayObject[i][0];
      _definition = arrayObject[i][1]; 
      break;
    }
  }

  return "<div style=\"padding: 2px; width: 250px;\" class=\"tableShadeDark\"><strong>" + _word + "</strong></div><div style=\"padding: 2px; width: 250px;\">" + _definition + "</div>";

//return "<strong>" + word + "</strong><br/>" + _definition;
}
