// Browsercheck
var agt=navigator.userAgent.toLowerCase(); 
var is_major = parseInt(navigator.appVersion); 
var is_minor = parseFloat(navigator.appVersion); 
var is_nav = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1) 
&& (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1) 
&& (agt.indexOf('webtv')==-1)); 
var is_nav4up = (is_nav && (is_major >= 4)); 
var is_ie = (agt.indexOf("msie") != -1); 
var is_ie4up = (is_ie && (is_major >= 4)); 
var is_op5 = (agt.indexOf("opera/5") != -1); 
var is_win = ( (agt.indexOf("win")!=-1) || (agt.indexOf("16bit")!=-1) );
var is_mac = (agt.indexOf("mac")!=-1);
var corrX = 0;
var corrY = 0;

if (is_ie4up) { corrY = 5; corrX = 40; }
else if (is_op5) { corrY = 5; corrX = 40; }
else if (is_nav) { corrY = 0; corrX = -27; } //Mozilla
else if (is_ie4up && is_mac) { corrY = 5; corrX = 40; }
else if (is_ie4up && is_win) { corrY = 5; corrX = 40; }
else if (is_ie4up || is_nav4up) { corrY = 5; corrX = 40; }
else { corrY = 0; corrX = 4; }

function Fensterweite () {
  if (window.innerWidth) {
    return window.innerWidth;
  } else if (document.body && document.body.offsetWidth) {
    return document.body.offsetWidth;
  } else {
    return 0;
  }
}

function Fensterhoehe () {
  if (window.innerHeight) {
    return window.innerHeight;
  } else if (document.body && document.body.offsetHeight) {
    return document.body.offsetHeight;
  } else {
    return 0;
  }
}

function neuAufbau () {
  if (Weite != Fensterweite() || Hoehe != Fensterhoehe())
    location.href = location.href;
}

/* Überwachung von Netscape initialisieren */
if (!window.Weite && window.innerWidth) {
  window.onresize = neuAufbau;
  Weite = Fensterweite();
  Hoehe = Fensterhoehe();
}

