onerror = stopError;
function stopError()
{
return true;
}
//Config
var CDROM = true; // CD-Rom und local  entweder oder
//var CDROM = false; // Internet und localhost
var berlinURL="http://localhost/inberlin/institut/";
// alt var berlinURL="http://me.in-berlin.de/~hirschfeld/institut/";
// neu
//var berlinURL="http://www.hirschfeld.in-berlin.de/institut/";
// Ende Config

var scrW = screen.width;
var scrH = screen.height;
//version gehört auch zum Rechstschutz sowie Opera Version 6
var version=parseInt(navigator.appVersion.charAt(0));

var res;
if (scrW >= "1024") res = 2;
else res = 3;
//Operaerkennung
var name_des_browsers;
var browser_userAgent;
var opera;
var browser_variable;
name_des_browsers=navigator.appName;
browser_userAgent=navigator.userAgent;

    if (name_des_browsers=="Netscape")
      {
       browser_variable="NS"
        if (browser_userAgent.indexOf ("compatible")>-1)
          {
            if (browser_userAgent.indexOf ("Opera")>-1)
             {
               // Der Opera-3/4-Browser wird verwendet
              browser_variable="VER3"
             }

           }
         else
           {
            if (browser_userAgent.indexOf ("Opera")>-1)
              {
               // Der Opera-5-Browser wird verwendet
             browser_variable="Opera"
                 if (browser_userAgent.indexOf ("Opera 5.")==-1)
                   {opera=6; }
              }

           }
        }

   if (name_des_browsers=="Microsoft Internet Explorer")
      {
        browser_variable="IE"
        if (browser_userAgent.indexOf ("Opera")>-1)
             {
               // Der Opera-5-Browser wird verwendet
               browser_variable="Opera";
               if (browser_userAgent.indexOf ("Opera 5.")== -1)
                   {opera=6;}
             }
       }

   if (name_des_browsers=="Opera")
      {
               // Der Opera-5-Browser wird verwendet
              browser_variable="Opera"
              if (browser_userAgent.indexOf ("Opera 5.")==  -1)
                   {opera=6;}


      }
      //Ende Operaerkennung


//Imternetexplorer auf Mac
   var agt=navigator.userAgent.toLowerCase();
  var is_mac    = (agt.indexOf("mac")!=-1);
   if ((browser_variable=="IE")&&(is_mac==true))
      {browser_variable="Opera";}





 //Rechtsschutz


if (navigator.appName=="Netscape" && version==4)
{
  window.document.captureEvents(Event.MOUSEDOWN);
}

window.document.onmousedown = taste;

function taste(evt)
  {
   if (navigator.appName=="Netscape")
     {
      if (evt.which==3)
       {
        cdinfo();
        return false;
       }
      }
    if (navigator.appName=="Microsoft Internet Explorer")
    {
     if (event.button==2)
      {
       cdinfo();
       return false;
      }
    }

  }

//ende Rechtsschutz
//Spracherkennung
var ie=document.all?1:0;
var ns=document.layers?1:0;
var dom=document.getElementById?1:0;
var sp=(ie||dom)?navigator.browserLanguage:navigator.language;
if (browser_variable=="NS" &&  version>=5)
    { sp=navigator.language;  }
 sp=sp.substring(0,2);


var winHilfe;
function hilfeShow()
{
winHilfe=window.open ("hilfe.html","ifsHilfe","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=700,height=500");
winHilfe.focus();
}
function hilfeShow1a()
{
winHilfe=window.open ("../hilfe.html#5","ifsHilfe","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=700,height=500");
winHilfe.focus();
}
function hilfeShow1b()
{
winHilfe=window.open ("../hilfe.html","ifsHilfe","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=700,height=500");
winHilfe.focus();
}

function hilfeShow2()
{
winHilfe=window.open ("../../hilfe.html","ifsHilfe","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=700,height=500");
winHilfe.focus();
}



var winSuche;
function sucheShow()
{
//CD-Rom
if (CDROM==true)
 {
if (res==2)
{winSuche=window.open ("suche_cd.html","ifsSuche","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=800,height=500");}
else
{winSuche=window.open ("suche_cd.html","ifsSuche","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=730,height=440");}
  }
else  //Internet
 {
 if (res==2)
{winSuche=window.open ("search.php","ifsSuche","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=790,height=500");}
else
{winSuche=window.open ("search.php","ifsSuche","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=60,top=10,width=730,height=440");}
 }
winSuche.focus();
}

//Gästebuch
var winGB;
function guest()
{
winGB=window.open ("http://www.hirschfeld.in-berlin.de/cgi-bin/perlsoft/main.cgi","winGB","menubar=yes,scrollbars=yes,resizable=yes,status=yes,left=50,top=15,width=750,height=400");
winGB.focus();
}

//ifsframe neue öffnen
function frameOpen (text)
{
if (browser_variable=="Opera")
   {
winIfsFrame=window.open("../ifsframe.html?"+text,"ifsframe","toolbar=yes,location=no,titelbar=yes,menubar=yes,scrollbars=yes,status=yes,resizable=yes");
   }
else if  (res ==2 && browser_variable=="IE")
    {
winIfsFrame=window.open("../ifsframe.html?"+text,"ifsframe","toolbar=yes,location=no,titelbar=yes,menubar=yes,scrollbars=yes,status=yes,resizable=yes,left=0,top=0,width=1017,height=622");
   }
else if  (res ==2 )
    {
winIfsFrame=window.open("../ifsframe.html?"+text,"ifsframe","toolbar=yes,location=no,titelbar=yes,menubar=yes,scrollbars=yes,status=yes,resizable=yes,left=0,top=0,width=1020,height=630");
   }
else if  (res ==3 && browser_variable=="IE")
    {
winIfsFrame=window.open("../ifsframe.html?"+text,"ifsframe","toolbar=yes,location=no,titelbar=yes,menubar=yes,scrollbars=yes,status=yes,resizable=yes,left=0,top=0,width=790,height=435");
   }
else
    {
winIfsFrame=window.open("../ifsframe.html?"+text,"ifsframe","toolbar=yes,location=no,titelbar=yes,menubar=yes,scrollbars=yes,status=yes,resizable=yes,left=0,top=0,width=790,height=445");
   }
winIfsFrame.focus();
 }
