function newWindow(file,name,NWwidth,NWheight,center,otherSet) {
    var over = false;
    var position = "";
    sHeight = screen.height;
    sWidth = screen.width;

    if (NWheight > (sHeight - 25)) {
      NWheight = sHeight - 55;
      NWwidth = NWwidth + 20;
      over = true;
    }
    if (NWwidth > sWidth) {
      NWwidth = sWidth - 10;
      NWheight = NWheight + 20;
      over = true;
    }
    if (center == "yes") {
      LeftPos = (sWidth > 0) ? ((sWidth-NWwidth)/2) : 0;
      TopPos = (sHeight > 0) ? ((sHeight-NWheight)/2) : 0;
      position = ',top='+TopPos+',left='+LeftPos ;
    }
    if ((over) && !(otherSet.indexOf("scrollbars"))) {
      otherSet = otherSet + ",scrollbars";
    }
    winSettings = "width=" + NWwidth + ",height=" + NWheight + position + otherSet;
    if (name == "") {
      name = "unnamed";
    }
    newWin = window.open(file,name,winSettings);
    if (newWin) return false;
    else return true;
  }

function toggle(target) {
      target = document.getElementById(target)
      status = (target.style.display != "block")?"block":"none";
      target.style.display = status;
      document.location = "#" + target.id;
      return false;
  }
