function doresize () 
	{location.reload();return false;}
if(document.layers)window.captureEvents(Event.RESIZE); window.onresize=doresize;

var  js10 = (document.images)?false:true; // NN2.x
var  js11 = (document.images) && ((window.screen)?false:true); // NN3.x
var  ie = ((document.all) && (window.offscreenBuffering)) ? true : false; // IE >= 4.x
var  isNS = ((document.captureEvents) && (!document.getElementById)) ? true : false; // NN4.x
var  mz = ((document.getElementById) && (!document.all) && (document.documentElement)) ? true : false; // NN6/MZ
var  op = ((document.getElementById) && (navigator.userAgent.indexOf('Opera') != -1)) ?true : false;
var isMacIE = ( (navigator.userAgent.indexOf("IE 4") > -1) && (navigator.userAgent.indexOf("Mac")  > -1) );

y=0; weiter=0;


function testen() 
{
br=0;
	if (ie)        
	{
	br=2;
	schicht='document.all["';stil='"].style';
	}
	if (isNS)        	
	{
	schicht='document.layers.mainDiv.document.layers["';stil='"]';
	}
	if (mz)
	{
	schicht='document.getElementById("';stil='").style';
	}
	if(op) 
	{
	schicht='document.getElementById("';stil='").style';
	}
	/* elsewindow.location.href="controlling.html"; // nur NN und IE !!!*/
}

function moveIt(wen,wert) 
{
test=y;  // Hilfsvariable
y+=wert;
if (y < -251 || y > 1) 
	{
	y=test;
	eval(schicht+wen+stil+'.top="'+y+'"');
}
else 
	{
	eval(schicht+wen+stil+'.top="'+y+'"');
	}
}

function scrollen(wert) 
{
moveIt('contentDiv',wert);
a=wert;
if ((weiter)&&(y<10)) setTimeout("scrollen(a)",1);
}

function gone()
{   
if(isNS)
	{   
	document.mainDiv.document.contentDiv.moveTo(105,10); 
	y=0;
	}   
if(ie)   
	{   
	contentDiv.style.pixelLeft=105;   
	contentDiv.style.pixelTop=10;
	y=0;
	}   
if(mz)
	{   
	document.getElementById("contentDiv").style.left="105px";    
	document.getElementById("contentDiv").style.top="10px";
	y=0;
	}
if(op)
	{   
	contentDiv.style.pixelLeft=105;   
	contentDiv.style.pixelTop=10;
	y=0;
	}
}
/* <!-- menu //--> */

userAgent = window.navigator.userAgent;
browserVers = parseInt(userAgent.charAt(userAgent.indexOf("/")+1),10);
function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		menue_01_back_over = newImage("../menu/Bilder/menue_01-back_over.gif");
		preloadFlag = true;
	}
}

function changeFrontImage(id)
{

if(id=="contentDiv")
  {
  //alert(id);
  document.getElementById("contentDiv").style.visibility="visible";
  document.getElementById("contentDiv2").style.visibility="hidden";
  document.getElementById("contentDiv").style.zIndex="5";
  document.getElementById("contentDiv2").style.zIndex="4";
  }
if(id=="contentDiv2")
  {
  //alert(id);
  document.getElementById("contentDiv").style.visibility="hidden";
  document.getElementById("contentDiv2").style.visibility="visible";
  document.getElementById("contentDiv").style.zIndex="4";
  document.getElementById("contentDiv2").style.zIndex="5";
  }
}

