/////////////////////////////////////////////////
function toggleMenuItem(id)
{
  tableData = document.getElementById(id);
  if(tableData.className == 'Menu2Item')
    tableData.className = 'Menu1Item';
  else
    tableData.className = 'Menu2Item';
}

/////////////////////////////////////////////////
function clickMenu1Item(id)
{
  if(id=='men1FrontPage')
    loadPage('index.php');
  else if(id=='men1News')
    loadPage('newsletter.php');
  else if(id=='men1Map')
    loadPage('map.php');
  else if(id=='men1Circum')
    loadPage('conditions.php');
  else if(id=='men1Hours')
    loadPage('hours.php');
}

/////////////////////////////////////////////////
function clickMenu2Item(cat)
{
  strUrl = 'showitems.php?category='+cat;
  loadPage(strUrl);
}

/////////////////////////////////////////////////
function showEMail(strName, strDomain, strSubject, strLink)
{
  document.write("<a href='mailto:"+strName+"@"+strDomain);

  if(strSubject != "")
    document.write("?subject="+strSubject);

  document.write("'>");

  if(strLink != "")
    document.write(strLink);
  else
    document.write(strName+"@"+strDomain)

  document.write("</a>");
}

/////////////////////////////////////////////////
function positionTopText()
{
  table      = document.getElementById('MainTable');
  divTopText = document.getElementById('TopText');
  divTopText.style.pixelLeft = table.offsetLeft+10; // Explorer
  divTopText.style.left = table.offsetLeft+10;      // Netscape
}
   
     
/////////////////////////////////////////////////
// URL handling functions
/////////////////////////////////////////////////
function loadPage(strURL)
{
  window.parent.location.href = strURL;
}
