function reDo(){parent.location.reload();}
parent.onresize = reDo;
/*____________________________scalierung, ausrichtung der seite____________________*/

function startcheck()	//wird im body-tag (onLoad) ausgefuehrt
{
browser_check();
}

function move()			//seite mitten am bildschirm platzieren
{ 
var breite2=screen.width;
var x=(breite2/2);
var fixpunkt_x=(x-((parent.outerWidth/2) || (parent.document.body.offsetWidth/2)));
var hoehe=screen.height-100;
var y=(hoehe/2);
var fixpunkt_y=(y-((parent.outerHeight/2) || (parent.document.body.offsetHeight/2)));
parent.moveTo(fixpunkt_x,fixpunkt_y);
}

function move_or_not()	//falls aufloesung!=1024 wird die seite mitten am bildschirm platziert
{
var breite3=screen.width;
if(breite3!=1024)
move();
else 
parent.moveTo(0,0);
}

function resize()
{
var breite=screen.width;
if (breite!=800)
parent.resizeTo(800,600);
}

function browser_check()
{
	if((document.all) && navigator.userAgent.toLowerCase().indexOf("mac")>-1){
	mac=1;
	}
	else if((document.layers) && navigator.userAgent.toLowerCase().indexOf("mac")>-1){
	mac=1;
	}

	else if(document.all && navigator.platform.indexOf("Win32")>-1){
	ie=1;
	}

	if(mac){
	neu=window.open('index_mac.html',"_parent");
	}
	
}

function open_flash()
{
	neu=window.open('frames/flash.html','flash','width=800,height=460,status=1,toolbar=1,menubar=1,location=1,scrollbars=0');
	neu.moveTo(0,0);
}

function open_gif()
{
	neu=window.open('frames/gif.html','flash','width=800,height=460,status=1,toolbar=1,menubar=1,location=1,scrollbars=0');
	neu.moveTo(0,0);
}

function set_scrollen(arg1,arg2)
{
	scrollen=arg1;
	TextLaenge=arg2;
}

function spruch_weg()
{
	setTimeout('parent.mainFrame.location.href=\'profil.html\'',6000);
}

function gif_weg()
{
	setTimeout('parent.location.href=\'../frameset/start_fs.html\'',9000);
}

/*________________________variablen fuer den scroller, browser-test, pc-mac-test________________________*/
var mac=0;			//plattform=macintosh
var w3c=0;			//netscape navigator 6.0
var netsc=0; 		//netscape navigator
var expl=0; 		//internet explorer
var Position=0;		//position des zu scrollenden textes
var Schritt=5;		//wie viel auf einmal vertikal zu springen/scrollen
var Pause=50;		//wie schnell (frequenz) wird gesprungen
var ar=0;			
var scrollen=0;		//soll auf dieser seite gescrollt werden oder nicht
var TextLaenge=0;
/*____________________________prüfen, ob browser > ver 5____________________*/
function w3c_test()
{
if(navigator.userAgent.indexOf("Mozilla/5") !=-1)
	{
			w3c=1;
			netsc=0; 
 			expl=0;		
	}
else 			
	{
		if (document.layers)  
 			{
 			netsc=1; 
 			expl=0; 
 			} 
		if (document.all)
 			{
 			netsc=0; 
 			expl=1;
 			}
	}
}


/*____________________________layer-voreinstellung, scroll-test____________________*/
function setVisibility()	//MUSS im body-tag (onLoad) aufgerufen werden
{
if(scrollen)
 {
 if(expl) document.all["Steuerung"].style.visibility="visible";
 if(netsc) document.layers["Steuerung"].visibility="visible";
 if(w3c) document.getElementById("Steuerung").style.visibility="visible";
 }
else
 {
 if(expl) document.all["Steuerung"].style.visibility="hidden";
 if(netsc) document.layers["Steuerung"].visibility="hide";
 if(w3c) document.getElementById("Steuerung").style.visibility="hidden";
 }	
}

function scroller_top()
{
	if(expl) document.all["Inhalt"].style.pixelTop=0;
	if(netsc) document.layers["Fenster"].document.layers["Inhalt"].top=0;
	if(w3c) document.getElementById("Inhalt").style.top=0+"px";
	Position=0;    
}



/*____________________________scroll-funktionen____________________*/

function hoch()
{
if(ar&&(Position>=TextLaenge*-1))
 	{
 		if(expl) document.all["Inhalt"].style.pixelTop=Position-Schritt;
 		if(netsc) document.layers["Fenster"].document.layers["Inhalt"].top=Position-Schritt;
 		if(w3c) document.getElementById("Inhalt").style.top=Position-Schritt+"px";                   
  		setTimeout('hoch()',Pause);
 		Position-=Schritt;
 	}
}

function runter()
{
if(ar&&(Position<0))
 {
 if(expl) document.all["Inhalt"].style.pixelTop=Position+Schritt;
 if(netsc) document.layers["Fenster"].document.layers["Inhalt"].top=Position+Schritt;
 if(w3c) document.getElementById("Inhalt").style.top=Position+Schritt+"px";
 setTimeout('runter()',Pause);
 Position+=Schritt;
 }
}
function change (strBildname, strGrafikname) {

      if (document.images) {
            document.images[strBildname].src = strGrafikname
        }
    }
