/************************************************************************************************'*/
// following from smackthemouse.com
// a script for IE because it doesn't observe max-width

function SetMaxWidth()
{
    if(document.getElementsByTagName)
    {
      window.onresize = new Function("window.location.reload()")
      var divs = document.getElementsByTagName("table"); 
      var maxWidth = 40;
      for (var i=0; i<divs.length; i++)
      { 
        var div = divs[i];
        if (div.getAttribute("id") == "container")
	{
	  var width;

	  if (document.body.clientWidth > maxWidth * parseInt(document.body.currentStyle.fontSize) * 4 / 3)
		{
			width = maxWidth + "em";
		}
	  else
		{
			width = "100%";
		}
	  div.style.width = width; 
          div.style.align = "center";
	}
      }
    }
}

var onItem = 0;
function toggle(thediv) 
{ 
  if (onItem != thediv) {
    if (onItem != 0)
      document.getElementById(onItem).style.display = "none"; 
    document.getElementById(thediv).style.display = "block"; 
    onItem = thediv;
  }
  else {
    document.getElementById(thediv).style.display = "none"; 
    onItem = 0;
  }
} 

