function SwitchDiv(idname) {
  var showDiv = document.getElementById("divs_"+idname);
  //HiddeDiv("login_box");
  if(showDiv != null) {
    if (showDiv.style.display == "none") {
    showDiv.style.display = "inline";}
    else if (showDiv.style.display == "inline") {
    showDiv.style.display = "none"}
    
  }

}

function SwitchImgDiv(imgname,swname) {
  var showImgDiv = document.getElementById(imgname);
  var showSwiDiv = document.getElementById(swname);
  //HiddeDiv("login_box");
  if(showImgDiv != null) {
    if (showImgDiv.style.display == "none") {
    showImgDiv.style.display = "inline";
	if (showSwiDiv != null) {showSwiDiv.innerHTML = "KI"}}
    else if (showImgDiv.style.display == "inline") {
    showImgDiv.style.display = "none";
    if (showSwiDiv != null) {showSwiDiv.innerHTML = "BE"}}
    
  }

}

function SwitchLink(idname,inText,offText) {
  var linkDiv = document.getElementById("switch_"+idname).innerHTML;
  //HiddeDiv("login_box");
  if(linkDiv == inText) document.getElementById("switch_"+idname).innerHTML = offText; else document.getElementById("switch_"+idname).innerHTML = inText;
}

function HiddeAllDivs(tabCount) {
  for(i = 1; i <= tabCount; i++) {
    if(document.getElementById("imgs_"+i) != null) {
      document.getElementById("imgs_"+i).style.display = "none"
    }
  }
}

function SwitchAllDivs(tabCount) {
  for(i = 0; i <= tabCount; i++) {
   	var showDiv = document.getElementById("imgs_"+i);
    if(showDiv != null) {
      if (showDiv.style.display == "none") {
    	showDiv.style.display = "inline";
		document.getElementById("imgshow").value = "inline";
		document.getElementById("imgswitch").innerHTML = "KI"}
      else if (showDiv.style.display == "inline") {
    	showDiv.style.display = "none";
		document.getElementById("imgshow").value = "none";
		document.getElementById("imgswitch").innerHTML = "BE"}
    }
  }
}

function HiddeDiv(tab) {
    if(document.getElementById(tab) != null) {
      document.getElementById(tab).style.display = "none"
    }
    
}

function ShowDiv(tab) {
    if(document.getElementById(tab) != null) {
      document.getElementById(tab).style.display = "inline"
    }
}

function BoldDiv(tab, event) {
    if(document.getElementById(tab) != null) {
      document.getElementById(tab).style.fontWeight = event
    }
}

