//browseridentifizierung_________________________________________________________

ie = (document.all) ? 1 : 0;
w3c = (!document.all && document.getElementById) ? 1 : 0;


// layerpositionierung___________________________________________________________
function posLayer() { // positionierung des parent-layers
  if(ie) {
    x = parseInt((document.body.offsetWidth - 780)/2);
    y = parseInt((document.body.offsetHeight - 500)/2);
    mainBox.style.left = x;
    mainBox.style.top = y;
  }
  if(w3c) {
    x = parseInt((window.innerWidth - 780)/2);
    y = parseInt((window.innerHeight - 500)/2);
	  document.getElementById('mainBox').style.left=x
	  document.getElementById('mainBox').style.top=y
  }
}

posLayer();
  
//________________________________________________________________________________