
function ShowLoc(index, e) {
  var thetext='<font color=blue><small>';
  switch (index) {
    case 0: thetext += 'Hammurabi'; break;
    case 1: thetext += 'Ammisaduga'; break;
    case 2: thetext += 'Shamshi-Adad 1'; break;
    case 3: thetext += 'Hattusilis 1'; break;
    case 4: thetext += 'Senuseret 3'; break;
    case 5: thetext += 'Amenemhat 3'; break;
    case 6: thetext += 'Neferhotep 1'; break;
    case 7: thetext += 'Ay'; break;
    case 8: thetext += 'Dudimose'; break;
    case 9: thetext += 'Joseph'; break;
    case 10: thetext += 'Ephraim'; break;
    case 11: thetext += 'Beriah'; break;
    case 12: thetext += 'Rephah'; break;
    case 13: thetext += 'Resheph'; break;
    case 14: thetext += 'Telah'; break;
    case 15: thetext += 'Tahan'; break;
    case 16: thetext += 'Laadan'; break;
    case 17: thetext += 'Ammihud'; break;
    case 18: thetext += 'Elishama'; break;
    case 19: thetext += 'Nun'; break;
    case 20: thetext += 'Amram'; break;
    case 21: thetext += 'Joshua'; break;
    case 22: thetext += 'Moses'; break;
    case 23: thetext += 'Aaron'; break;
    case 24: thetext += 'Jethro'; break;
    case 25: thetext += 'Caleb'; break;
    case 26: thetext += 'Annitas'; break;
  }
  thetext += '</small></font>' 
  identity.innerHTML=thetext;
  bubble.style.left=e.x + document.body.scrollLeft;
  bubble.style.top=e.y-60 + document.body.scrollTop;
  bubble.style.visibility = 'visible';
}

function HideLoc() {
  bubble.style.visibility = 'hidden';
}

function DoExplain(trigger) 
{
  theText='';
  switch (trigger)
  {
    case 0: theText="<h3>Israel - sojourn</h3>Few names are known to help bridge the gap between Joseph - last representative of the patriarchs - and Moses as instigator and leader of the Exodus. The majority of the individuals chosen are of the family line of Ephraim, listed in 1 Chronicles 6. The sequence helps to establish an estimate of overall duration.";break;
    case 1: theText="<h3>Middle kingdom</h3>12th dynasty<br><br>An important and powerful dynasty, during which the power of local officials (nomarchs) was broken and authority centralised.";break;
    case 2: theText="<h3>Hatti (the Hittites)</h3>The Hittite Kingdom<br><br>";break;
    case 3: theText="<h3>2nd Intermediate Period</h3>13th dynasty<br><br>Early weak, short-lived rulers were followed by stronger men who enforced Egyptian authority, but the dynasty ended in collapse.";break;
    case 4: theText="<h3>Patriarchs</h3>The family leaders from Abraham to Joseph form a distinctive part of the Genesis account. It was a period of migration, beginning with a pastoral life in Mesopotamia and ending with a position of power and responsibility in Egypt.";break;
    case 5: theText="<h3>Exodus/Judges</h3>After establishing a presence in the land of Canaan, the Israelite tribes were loosely organised and easily subdued by others. The duration of this period is difficult to estimate reliably. The issues involved are discussed on the <a href=exjudgescontext.htm>Exodus and Judges page</a>.";break;
    case 6: theText="<h3>Larsa</h3>A city in the southern part of Mesopotamia which arose to dominance after the fall of Ur III. Its period of flourishing was marked by continual rivalry and conflict with Isin.";break;
    case 7: theText="<h3>Isin</h3>A city in the central part of Mesopotamia which arose to dominance after the fall of Ur III. Its period of flourishing was marked by continual rivalry and conflict with Larsa. ";break;    
    case 8: theText="<h3>Old Assyrian period</h3>This period is largely based on the city of Asshur, and extends from during patriarchal times.";break;
    case 9: theText="<h3>Old Babylonian period</h3>Early expansion led to conflict and eventual capture of Isin and Larsa. At its height, the territory controlled was approximately the same as that of Ur III.";break;
    case 10: theText="<h3>Middle kingdom</h3>From part-way through the 11th dynasty, central authority and unity were recovered, and Egypt once more took a prominent part in international affairs.";break;
    case 11: theText="<h3>2nd Intermediate Period</h3>A period of turmoil and confusion which lasted nearly 4 centuries until the establishment of the 18th dynasty.";break;
    case 12: theText="<h3>2nd Intermediate Period</h3>15th and 17th dynasties<br><br>Two dynasties existing in parallel, one based around Thebes and the other in the Delta region. The conventional and New Chronologies reverse the interpretation of which was which.";break;
    case 13: theText="<h3>New Chronology dates</h3>.";break;
    case 14: theText="<h3>Conventional dates</h3>Assuming a Middle Bronze Exodus at the end of the 13th dynasty.";break;
    case 15: theText="<h3>Conventional dates</h3>Assuming a Late Bronze Exodus around the reign of Thutmose III.";break;
    case 16: theText="<h3>New Kingdom</h3>This was another period of strength, lasting around 400 years, in which a number of powerful military conquerers extended their sway well beyond the borders of Egypt. Some of the best-known Pharaohs date from this era. ";break;
    case 17: theText="<h3>New Kingdom</h3>18th dynasty<br><br>With this dynasty, Egypt was once again reunited under one central rule and able to take a more vigorous part in external affairs. However, after strong early figures, rulers became more inward-looking, allowing surrounding nations to become strong. The middle years of the dynasty are associated with a lengthy correspondence with rulers of other regions, called the Amarna letters. ";break;
  }
  expl.innerHTML=theText;
}

ncstart=1800;
ocstart=1800;
ncjsph=1700;
ncjsphl=110;
ocjsph=1827;
ocjsphl=110;
ncpats=1800;
ncpatsl=200;
ocpats=1830;
ocpatsl=100;
ncexj=1450;
ncexjl=140;
ocexj1=1641;
ocexjl1=290;
ocexj2=1500;
ocexjl2=150;
ncegmk=1800;
ncegmkl=168;
nceg2ip=1632;
nceg2ipl=250;
ocegmk=1840;
ocegmkl=81;
oceg2ip=1759;
oceg2ipl=231;
ocegnk=1528;
ocegnkl=175;
ncd12=1796;
ncd12l=164;
ocd12=1840;
ocd12l=81;
ncd13=1632;
ncd13l=187;
ocd13=1759;
ocd13l=118;
ncd15=1445;
ncd15l=70;
ocd15=1636;
ocd15l=108;
ocd17=1641;
ocd17l=102;
ocd18=1539;
ocd18l=186;
ncsen3=1696;
ncsen3l=38;
ocsen3=1836;
ocsen3l=19;
ncamn3=1678;
ncamn3l=46;
ocamn3=1817;
ocamn3l=45;
ncnf=1542;
ncnfl=10;
ocnf=1705;
ocnfl=10;
ncay=1499;
ncayl=23;
ocay=1679;
ocayl=23;
ncddm=1457;
ncddml=4;
ocddm=1645;
ocddml=4;
nclarsa=1798;
nclarsal=262;
ncisin=1805;
ncisinl=236;
oclarsa=1805;
oclarsal=46;
ocisin=1805;
ocisinl=13;
ncoldass=1710;
ncoldassl=360;
ncshmsh=1584;
ncshmshl=32;
ocoldass=1807;
ocoldassl=354;
ocshmsh=1807;
ocshmshl=32;
ncoldbab=1667;
ncoldbabl=305;
ncham=1565;
nchaml=43;
ncammis=1419;
ncammisl=21;
ocoldbab=1805;
ocoldbabl=209;
ocham=1792;
ochaml=43;
ocammis=1647;
ocammisl=21;
nchatti=1600;
nchattil=225;
ochatti=1800;
ochattil=350;
ncann=1575;
ncannl=25;
nchat1=1420;
nchat1l=30;
ocann=1775;
ocannl=25;
ochat1=1650;
ochat1l=30;

function DoPosition() {
  c18.style.top=250 + (ncstart-1800);
  c18l.style.top=225 + (ncstart-1800);
  c17.style.top=250 + (ncstart-1700);
  c17l.style.top=225 + (ncstart-1700);
  c16.style.top=250 + (ncstart-1600);
  c16l.style.top=225 + (ncstart-1600);
  c15.style.top=250 + (ncstart-1500);
  c15l.style.top=225 + (ncstart-1500);
  c14.style.top=250 + (ncstart-1400);
  c14l.style.top=225 + (ncstart-1400);
  expl.style.left=710;
  expl.style.top=290;
  expl.style.width=240; 
  expl.style.height=261;
  expl.style.visibility="visible";
  legend.style.left=110;
  legend.style.top=775;
  legend.style.width=640; 
  legend.style.height=120;
  legend.style.visibility="visible";
  notes.style.top = 900;
  notes.style.left = 110;
  notes.style.visibility = "visible";
  DoNCPosition();
}

function DoNCPosition() {
  exodus.style.top=250 + (ncstart-1450);
  exodusl.style.top=225 + (ncstart-1450);
  textnc.fillcolor="RGB(255,233,185)";
  textoc1.fillcolor="RGB(251,244,239)";
  textoc2.fillcolor="RGB(251,244,239)";
  joseph.style.top=250 + (ncstart-ncjsph);
  joseph.style.height=ncjsphl;
  joseph.style.left=175;
  egyptmk.style.top=250 + (ncstart-ncegmk);
  egyptmk.style.height=ncegmkl;
  egyptmk.style.left=450;
  egyptmktop.style.top=250 + (ncstart-ncegmk);
  egyptmktop.style.left=450;
  egypt2ip.style.top=250 + (ncstart-nceg2ip);
  egypt2ip.style.height=nceg2ipl;
  egypt2ip.style.left=450;
  egypt2ipbase.style.visibility="visible";
  egypt2ipbase.style.top=50 + (ncstart-nceg2ip+nceg2ipl);
  egypt2ipbase.style.left=450;
  egyptnk.style.visibility="hidden";
  egyptnkbase.style.visibility="hidden";
  d12.style.top=250 + (ncstart-ncd12);
  d12.style.height=ncd12l;
  d12.style.left=460;
  d13.style.top=250 + (ncstart-ncd13);
  d13.style.height=ncd13l;
  d13.style.left=475;
  d15.style.top=250 + (ncstart-ncd15);
  d15.style.height=ncd15l;
  d15.style.left=460;
  d17.style.visibility="hidden";
  d18.style.visibility="hidden";
  sen3.style.top=250 + (ncstart-ncsen3);
  sen3.style.height=ncsen3l;
  sen3.style.left=453;
  amn3.style.top=250 + (ncstart-ncamn3);
  amn3.style.height=ncamn3l;
  amn3.style.left=468;
  nf1.style.top=250 + (ncstart-ncnf);
  nf1.style.height=ncnfl;
  nf1.style.left=482;
  ay.style.top=250 + (ncstart-ncay);
  ay.style.height=ncayl;
  ay.style.left=482;
  ddm.style.top=250 + (ncstart-ncddm);
  ddm.style.height=ncddml;
  ddm.style.left=482;
  larsa.style.top=250 + (ncstart-nclarsa);
  larsa.style.height=nclarsal;
  larsa.style.left=525;
  isin.style.top=250 + (ncstart-ncisin);
  isin.style.height=ncisinl;
  isin.style.left=550;
  oldass.style.top=250 + (ncstart-ncoldass);
  oldass.style.height=ncoldassl;
  oldass.style.left=575;
  shmsh.style.top=250 + (ncstart-ncshmsh);
  shmsh.style.height=ncshmshl;
  shmsh.style.left=582;
  oldbab.style.top=250 + (ncstart-ncoldbab);
  oldbab.style.height=ncoldbabl;
  oldbab.style.left=600;
  ham.style.top=250 + (ncstart-ncham);
  ham.style.height=nchaml;
  ham.style.left=607;
  ammis.style.top=250 + (ncstart-ncammis);
  ammis.style.height=ncammisl;
  ammis.style.left=607;
  hatti.style.top=250 + (ncstart-nchatti);
  hatti.style.height=nchattil;
  hatti.style.left=625;
  ann.style.top=250 + (ncstart-ncann);
  ann.style.height=ncannl;
  ann.style.left=632;
  hat1.style.top=250 + (ncstart-nchat1);
  hat1.style.height=nchat1l;
  hat1.style.left=632;
}

function DoOCPosition(index) {
  textnc.fillcolor="RGB(251,244,239)";
  joseph.style.top=250 + (ocstart-ocjsph);
  joseph.style.height=ocjsphl;
  joseph.style.left=175;
  if (index==1)
  {
    exodus.style.top=250 + (ncstart-1640);
    exodusl.style.top=225 + (ncstart-1640);
    textoc1.fillcolor="RGB(255,233,185)";
    textoc2.fillcolor="RGB(251,244,239)";
  } else {
    exodus.style.top=250 + (ncstart-1400);
    exodusl.style.top=225 + (ncstart-1400);
    textoc1.fillcolor="RGB(251,244,239)";
    textoc2.fillcolor="RGB(255,233,185)";
  }
  egyptmk.style.top=250 + (ocstart-ocegmk);
  egyptmk.style.height=ocegmkl;
  egyptmk.style.left=450;
  egyptmktop.style.top=250 + (ocstart-ocegmk);
  egyptmktop.style.left=450;
  egypt2ip.style.top=250 + (ocstart-oceg2ip);
  egypt2ip.style.height=oceg2ipl;
  egypt2ip.style.left=450;
  egypt2ipbase.style.visibility="hidden";
  egyptnk.style.visibility="visible";
  egyptnk.style.top=250 + (ocstart-ocegnk);
  egyptnk.style.left=450;
  egyptnk.style.height=ocegnkl;
  egyptnkbase.style.visibility="visible";
  egyptnkbase.style.top=50 + (ocstart-ocegnk+ocegnkl);
  egyptnkbase.style.left=450;
  d12.style.top=250 + (ocstart-ocd12);
  d12.style.height=ocd12l;
  d12.style.left=460;
  d13.style.top=250 + (ocstart-ocd13);
  d13.style.height=ocd13l;
  d13.style.left=475;
  d15.style.top=250 + (ocstart-ocd15);
  d15.style.height=ocd15l;
  d15.style.left=455;
  d17.style.visibility="visible";
  d17.style.top=250 + (ocstart-ocd17);
  d17.style.height=ocd17l;
  d17.style.left=465;
  d18.style.visibility="visible";
  d18.style.top=250 + (ocstart-ocd18);
  d18.style.height=ocd18l;
  d18.style.left=475;
  sen3.style.top=250 + (ocstart-ocsen3);
  sen3.style.height=ocsen3l;
  sen3.style.left=455;
  amn3.style.top=250 + (ocstart-ocamn3);
  amn3.style.height=ocamn3l;
  amn3.style.left=467;
  nf1.style.top=250 + (ocstart-ocnf);
  nf1.style.height=ocnfl;
  nf1.style.left=482;
  ay.style.top=250 + (ocstart-ocay);
  ay.style.height=ocayl;
  ay.style.left=482;
  ddm.style.top=250 + (ocstart-ocddm);
  ddm.style.height=ocddml;
  ddm.style.left=482;
  larsa.style.top=250 + (ocstart-oclarsa);
  larsa.style.height=oclarsal;
  larsa.style.left=525;
  isin.style.top=250 + (ocstart-ocisin);
  isin.style.height=ocisinl;
  isin.style.left=550;
  oldass.style.top=250 + (ocstart-ocoldass);
  oldass.style.height=ocoldassl;
  oldass.style.left=575;
  shmsh.style.top=250 + (ocstart-ocshmsh);
  shmsh.style.height=ocshmshl;
  shmsh.style.left=582;
  oldbab.style.top=250 + (ocstart-ocoldbab);
  oldbab.style.height=ocoldbabl;
  oldbab.style.left=600;
  ham.style.top=250 + (ocstart-ocham);
  ham.style.height=ochaml;
  ham.style.left=607;
  ammis.style.top=250 + (ocstart-ocammis);
  ammis.style.height=ocammisl;
  ammis.style.left=607;
  hatti.style.top=250 + (ocstart-ochatti);
  hatti.style.height=ochattil;
  hatti.style.left=625;
  ann.style.top=250 + (ocstart-ocann);
  ann.style.height=ocannl;
  ann.style.left=632;
  hat1.style.top=250 + (ocstart-ochat1);
  hat1.style.height=ochat1l;
  hat1.style.left=632;
}


