//Fenster Öffnen (image.htm)
function showPopup(sFile,w,h,f,c,t,n)
  {
    t=escape(t)
    sFile = 'image.htm?'+sFile+'&'+w+'&'+h+'&'+f+'&'+c+'&'+t+'&'+n;
    vX =  screen.width / 2 - w / 2
    vY =  screen.height / 2 - h / 2
    
    document.location.href=sFile
  }
  
  

//Irgendein Fenster öffnen
  function showWindow(sFile,h,w)
{
      // Alle anderen Browser (MAC IE5)  
      {
      vX =  screen.width / 2 - w / 2
      vY =  screen.height / 2 - h / 2
      }
  Fenster = window.open(sFile,null,"left="+vX+",top="+vY+",height="+h+",width="+w+",status=no,toolbar=no,menubar=no,location=no,scrollbars=no");
  Fenster.focus() 

}


//Bei Popups
//Opener abfragen und vergleichen
function getLocationPopup(){
  
  if(window.opener && !window.opener.closed){
    //alert(opener.document.location.pathname);
  }else {
    document.location.href='index.htm';
  }
}

//Überprüfen ob eine Datei imzugehörigen Frameset aufgerufen wurde
function getLocation(){
//	alert(top.location.pathname)
  sUrl=top.document.location.href.toLowerCase()

  if(sUrl.indexOf("index.htm") == -1) {
  //alert(document.location.href+":"+top.location.href)
    document.location.href = 'index.htm';
  }
}


