function docWriteFlash(file, width, height) {

	obj_tag = "<object type=\"application/x-shockwave-flash\" data=\"" + file + "\" width=\"" + width + "\" height=\"" + height + "\">";

	obj_tag += "<param name=\"type\" value=\"application/x-shockwave-flash\" />";

	obj_tag += "<param name=\"pluginurl\" value=\"http://www.macromedia.com/go/getflashplayer\" />";

	obj_tag += "<param name=\"movie\" value=\"" + file + "\" />";

	obj_tag += "<param name=\"quality\" value=\"high\" />";

	obj_tag += "<param name=\"wmode\" value=\"transparent\" />";

	obj_tag += "<img src=\"..\/..\/shared\/images\/rud_head.jpg\" width=\"181\" height=\"100\" alt=\"\" />";

	obj_tag += "</object>";

	document.write(obj_tag);

	

}

function hald_tickeropen(url){
	window.open(url,'','width=500,statusbar=no,toolbar=no,scrollbars=yes');
	void(0);
}

function hald_open_operationwin(myfile,width,height){

	if( !width ) width = 400;

	if( !height ) height = 400;

	var now=new Date()

	winname="a" + now.getTime()

	params = "width="+width+",height="+height+",resizable=1,status=0,toolbar=0,location=0,directories=0,menubar=0,scrollbars=0 ";

	newwin = window.open( myfile, winname , params);
	
	newwin.moveTo(230, 270);

	if( window.focus ) newwin.focus();

}

function hald_openwin(myfile,width,height){

	if( !width ) width = 400;

	if( !height ) height = 400;

	var now=new Date()

	winname="a" + now.getTime()

	params = "width="+width+",height="+height+",resizable=1,status=0,toolbar=0,location=0,directories=0,menubar=0,scrollbars=1 ";

	newwin = window.open( myfile, winname , params)
	newwin.moveTo(200, 250);
	if( window.focus ) newwin.focus();

}



function hald_openwin_movie(myfile,width,height){

	if( !width ) width = 400;

	if( !height ) height = 400;
	
	width = 340;
	//height = 331;

	var now=new Date()

	winname="a" + now.getTime()

	params = "width="+width+",height="+height+",resizable=0,status=0,toolbar=0,location=0,directories=0,menubar=0,scrollbars=0 ";

	newwin = window.open( myfile, winname , params)

	if( window.focus ) newwin.focus();

}


function hald_openwin_moviebig(myfile,width,height){

	if( !width ) width = 600;

	if( !height ) height = 500;
	
	width = 540;
	height = 481;

	var now=new Date()

	winname="a" + now.getTime()

	params = "width="+width+",height="+height+",resizable=0,status=0,toolbar=0,location=0,directories=0,menubar=0,scrollbars=0 ";

	newwin = window.open( myfile, winname , params)

	if( window.focus ) newwin.focus();

}


function resizeDivTbl() {

    

	iDivHeight = document.body.offsetHeight;

	

	// Hhe der Div ndern

	oDivList = document.getElementById('divTbl');

	oDivList.style.height = (iDivHeight - CiDivListDiff) + 'px';

        

}
function sloagan_bottom(){
		  var exist=document.getElementById('content_text_ringringsystem');
		  if (exist) {
			  slogan = document.getElementById('slogan_bottom');
			  slogan.heigth = "20px";
		  }
}

function resizeContents() {
	oDivgeschichte  = document.getElementById('geschichte');
	if(oDivgeschichte!=null) {
		changeImage();
	}
	oDivContentLayout  = document.getElementById('content');
	oDivTicker  = document.getElementById('ticker');
	oDivContLayout  = document.getElementById('cont');
	oDivNaviLeft    = document.getElementById('navi_left');
	oDivNaviLeftTable   = document.getElementById('navi_left_table');
	oDivNaviLeftTable_out   = document.getElementById('navi_left_table_out');
	
	if(oDivNaviLeftTable_out !=null){ //Normaler Bereich
	
		if ((oDivNaviLeftTable_out.offsetHeight )< oDivContentLayout.offsetHeight ) {
				
			var sNewHeight = (oDivContLayout.offsetHeight)+ 'px';
		} else {
			var sNewHeight = (oDivNaviLeftTable_out.offsetHeight)+30 + 'px';
	
		}	
	
		oDivNaviLeftTable_out.style.height = sNewHeight;
		
	}else if(oDivNaviLeft != null){ //Adminbereich
		
		if ((oDivNaviLeft.offsetHeight )< oDivContentLayout.offsetHeight ) {
				
			var sNewHeight = (oDivContLayout.offsetHeight)+ 'px';
		} else {
			var sNewHeight = (oDivNaviLeft.offsetHeight)+ 30 + 'px';
	
		}
		
		oDivNaviLeft.style.height 		= sNewHeight;
		
	}	
	
	
	oDivContentLayout.style.height =  sNewHeight;
	
	if (oDivTicker != null && oDivTicker.name == "ticker") {
		oDivContLayout.style.height = "499px";
	}
}
function getE(obj) {
	return document.getElementById(obj);
}

function changeOpacity(opacity, ID) { 
	
	oElem = getE(ID);
	oElem.style.filter = "alpha(opacity=" + opacity + ")";
	oElem.style.opacity = (opacity / 101); 
	oElem.style.MozOpacity = (opacity / 101); 
	oElem.style.KhtmlOpacity = (opacity / 101); 
	
}

function changeImage() { 
	
	oElem = getE('SampleID');
	changeOpacity(0, 'SampleID');
	
	//oElem.src = "<!--{@ LOOP_STD_DATA}-->{.geschichte_img}<!--{/}--> ";
	
	
	var zaehler = 0;
	var geschwindigkeit = 10; 
	
	//Bild faden
	for(i = 0; i <= 100; i++) { 
		setTimeout("changeOpacity("+i+", 'SampleID')",(zaehler*geschwindigkeit)); 
		zaehler++; 
	}
	
}
function resize() {
	resizeContents;
	sloagan_bottom;
}
window.onload = resizeContents;


