function Guid(){
		var keylist="abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; 
		var arrGuidLength=Array(8,4,4,4,12);
		this.Id=function(){
			var strGuid="";
			for(var agc=0;agc<arrGuidLength.length;agc++){var strTemp="";for (var i=0;i<arrGuidLength[agc];i++){strTemp+=keylist.charAt(Math.floor(Math.random()*keylist.length));};strGuid+=((strGuid.length>0) ? "-" : "" ) + strTemp.toUpperCase();};
			return strGuid;
		}
		this.Empty=function(){
			var strGuid="";
			for(var agc=0;agc<arrGuidLength.length;agc++){var strTemp="";for (var i=0;i<arrGuidLength[agc];i++){strTemp+="0";};strGuid+=((strGuid.length>0) ? "-" : "" ) + strTemp.toUpperCase();};
			return strGuid;
		}
}
Guid.prototype = new Guid();

var DD = new Object();

DD.config = new Object();
	DD.config.isIE    = (document.all) ? true : false;
	DD.config.isOpera = (document.all && !document.styleSheets && navigator.appName.toLowerCase()=="opera") ? true : false;
	DD.config.isOSWin = (navigator.appVersion.indexOf('Win') != -1) ? true : false;

DD.PopUpWindow=new Object();
DD.PopUpWindow.Open=function(winUrl,winName,winFeatures){
	try{
		var oWindow = window.open( '',winName, winFeatures, true ) ;
		if ( !oWindow ){
			alert('Bitte schalten Sie den Popupblocker aus, um fortzufahren!');
			return ;
		}
		oWindow.focus() ;
		oWindow.location.href = winUrl ;
		oWindow.opener=self;
		oWindow.creator=self;		
	}catch(ex){
		alert('Bitte schalten Sie den Popupblocker aus, um fortzufahren!');
	}
}

DD.findPosX = function(obj){
	var curleft = 0;
	if (obj.offsetParent){while (obj.offsetParent){curleft += obj.offsetLeft;obj = obj.offsetParent;};}else if (obj.x){curleft += obj.x;}
	return curleft;
}
DD.findPosY = function(obj){
	var curtop = 0;
	if (obj.offsetParent){while (obj.offsetParent){curtop += obj.offsetTop;obj = obj.offsetParent;};}else if (obj.y){curtop += obj.y;}
	return curtop;
}

DD.loadElements=Array();
DD.addLoadElement=function(strLoad){
	DD.loadElements[DD.loadElements.length]=strLoad;
}

DD.resizeElements=Array();
DD.addResizeElement=function(strLoad){
	DD.resizeElements[DD.resizeElements.length]=strLoad;
}

DD.isPageLoaded=false;

DD.fixPageHeight=function(){
	var sys_avail_winheight=((DD.config.isOpera) ? window.innerHeight : document.documentElement.clientHeight);

	if(sys_avail_winheight > ( ( $("dvMainInner").offsetHeight + $("dvFooter").offsetHeight ) + 10 ) ){
		$("dvMain").style.height = ( sys_avail_winheight -  ($("dvFooter").offsetHeight + 10 ) ) + "px";
	}else{
		$("dvMain").style.height = $("dvMainInner").offsetHeight + "px";
	}
	
}
var fixBG=false;
DD.fixPageBackground = function(){
	var bdyObj = document.getElementsByTagName("BODY")[0];
	var bdySizes=(bdyObj.offsetHeight-($("dvWebSolutionBy").offsetHeight+$("dvContentFooter").offsetHeight));
	bdyObj.style.backgroundPosition="center " + (bdySizes - (900 - 96)) + "px";
}
DD.loadInit=function(){
	//fixBG=setInterval("DD.fixPageBackground()",1);
	for(var l=0;l<DD.loadElements.length;l++){
		eval(DD.loadElements[l]);
	}
  DD.isPageLoaded=true;
  createJSdependendControls();
}
DD.resizeInit=function(){
	//DD.fixPageHeight();
	for(var l=0;l<DD.resizeElements.length;l++){
		eval(DD.resizeElements[l]);
	}
}

DD.changeBackground=function(callObj,hexColor){
	callObj.style.backgroundColor=hexColor;
}

/*neu*/
DD.clearValue = function(callObj,defValue,isFocus){
	if(isFocus){
		if(callObj.value==defValue){callObj.value="";}
	}else{
		if(callObj.value==""){callObj.value=defValue;}
	}
}


DD.fontSize=function(callObj,intSize,strOperator,seIDM){
	document.getElementById("fontSizeChanger").src="/?fontSize=" + intSize;
}




window.onload=DD.loadInit;
window.onresize=DD.resizeInit;

function $() {
	var elements = new Array();
	for (var i = 0; i < arguments.length; i++) {
		var element = arguments[i];
		if (typeof element == 'string')
			element = document.getElementById(element);
		if (arguments.length == 1)
			return element;
		elements.push(element);
	}
	return elements;
}

var keylist="abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
DD.giveMeTempName=function(intLen){
	var temp="";
	for (var i=0;i<intLen;i++){temp+=keylist.charAt(Math.floor(Math.random()*keylist.length));}
	return temp.toUpperCase();
}
DD.newGuid=function(){
	var arrGuidLength=Array(8,4,4,4,12);
	var strGuid="";
	for(var agc=0;agc<arrGuidLength.length;agc++){if(strGuid.length==0){strGuid=this.giveMeTempName(arrGuidLength[agc]);}else{strGuid+="-"+this.giveMeTempName(arrGuidLength[agc])}}
	return strGuid;
}


DD.printIt=function(){
	if (window.print) {
		window.print();
	} else {
		var WebBrowser = '<OBJECT ID="WebBrowser1" WIDTH=0 HEIGHT=0 CLASSID="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2"></OBJECT>';
		document.body.insertAdjacentHTML('beforeEnd', WebBrowser);
		WebBrowser1.ExecWB(6, 2);	//Use a 1 vs. a 2 for a prompting dialog box WebBrowser1.outerHTML = "";
	}
}
DD.send2friend=function(){

}


function HREF(_path,_target,_first_param,_second_param,_third_param){
		if(!_target || (_target && (_target=="" || _target=="_self"))){
			window.location.replace(_path);
		}else if(_target=="_top"){
			top.window.location.replace(_path);
		}else if(_target=="_popup" && _first_param && _second_param){
			DD.PopUpWindow.Open(_path,_first_param,_second_param);
		}else if(_target=="_virtual" && _first_param && _second_param && _third_param){
			DD.PopUpWindow.Virtual(_path,_first_param,_second_param,_third_param);
		}else{
			window.open(_path,_target);
		}
	}

DD.validation = new Object();
	DD.validation.OnDemand = new Object();
		DD.validation.OnDemand.isNumber = function(callObj){
			callObj.value=callObj.value.replace(/([a-z]|ü|ö|ä|à|á|ý|ù|í|ì|è|é)/gi,"");
		}

function createJSdependendControls() {	
	if(document.getElementById('dvContentSujets')) {
		// Create SlideShowControls
		var slideShowSpan = document.createElement('span');
			slideShowSpan.id = 'slideShowControls';
			slideShowSpan.style.backgroundImage = 'url(/images/icons/ico_thumbnail_' + ( getCookie('SlideShow') == 'false' ? 'play' : 'stop' ) + 'gallery.gif)';
		var slideShowLink = document.createElement('a');
			slideShowLink.id = 'slideShowControl';
			slideShowLink.href = 'javascript:slideShow();';
			slideShowLink.innerHTML = 'Slide-Show ' + ( getCookie('SlideShow') == 'false' ? 'starten' : 'anhalten' );
	
		var insertInto = document.getElementById('dvContentSujets');
			insertInto.appendChild(slideShowSpan);
			slideShowSpan.appendChild(slideShowLink);
	}
}

function createJSControlFontSizeMax(newFontSize,currentNode,tabIndex,width,height) {
	var fontSizeIncrease = document.createElement('div');
		fontSizeIncrease.id = 'dvFontSizeMod_maximize';
		var fontSizeIncreaseLink = document.createElement('a');
			fontSizeIncreaseLink.href = 'javascript:DD.fontSize(this,' + newFontSize + ',"' + currentNode + '");';
			fontSizeIncreaseLink.tabIndex = '"' + tabIndex + '"';
			fontSizeIncreaseLink.setAttribute("onmouseover","DD.navi.highlightMetaNavi(this,1,true)",false);
			fontSizeIncreaseLink.setAttribute("onmouseout","DD.navi.highlightMetaNavi(this,1,false)",false);

		var fontSizeIncreaseImg = document.createElement('img');
			fontSizeIncreaseImg.src = '/images/meta/ico_nav_fontsize_max_off.gif';
			fontSizeIncreaseImg.alt = 'Schriftgr&ouml;sse erh&ouml;hen';
			fontSizeIncreaseImg.style.width = width;
			fontSizeIncreaseImg.style.height = height;

	var insertInto = document.getElementById('dvFontSizeModifier');
		insertInto.appendChild(fontSizeIncrease);
		fontSizeIncrease.appendChild(fontSizeIncreaseLink);
		fontSizeIncreaseLink.appendChild(fontSizeIncreaseImg);
}

function createJSControlFontSizeMin(newFontSize,currentNode,tabIndex,width,height) {
	var fontSizeDecrease = document.createElement('div');
		fontSizeDecrease.id = 'dvFontSizeMod_minimize';
		var fontSizeDecreaseLink = document.createElement('a');
			fontSizeDecreaseLink.href = 'javascript:DD.fontSize(this,' + newFontSize + ',"' + currentNode + '");';
			fontSizeDecreaseLink.tabIndex = '"' + tabIndex + '"';
			fontSizeDecreaseLink.setAttribute("onmouseover","DD.navi.highlightMetaNavi(this,0,true)",false);
			fontSizeDecreaseLink.setAttribute("onmouseout","DD.navi.highlightMetaNavi(this,0,false)",false);

		var fontSizeDecreaseImg = document.createElement('img');
			fontSizeDecreaseImg.src = '/images/meta/ico_nav_fontsize_min_off.gif';
			fontSizeDecreaseImg.alt = 'Schriftgr&ouml;sse minimieren';
			fontSizeDecreaseImg.style.width = width;
			fontSizeDecreaseImg.style.height = height;

	var insertInto = document.getElementById('dvFontSizeModifier');
		insertInto.appendChild(fontSizeDecrease);
		fontSizeDecrease.appendChild(fontSizeDecreaseLink);
		fontSizeDecreaseLink.appendChild(fontSizeDecreaseImg);
}

function createJSControlFontSizeNorm(currentNode,tabIndex) {
	var fontSizeNormalize = document.createElement('div');
		fontSizeNormalize.id = 'dvFontSizeMod_normalize';
		var fontSizeNormalizeLink = document.createElement('a');
			fontSizeNormalizeLink.href = 'javascript:DD.fontSize(this,11,"' + currentNode + '");';
			fontSizeNormalizeLink.tabIndex = '"' + tabIndex + '"';
			fontSizeNormalizeLink.innerHTML = 'Schriftgr&ouml;sse';

	var insertInto = document.getElementById('dvFontSizeModifier');
		insertInto.appendChild(fontSizeNormalize);
		fontSizeNormalize.appendChild(fontSizeNormalizeLink);
}

function slideShow() {
	if(getCookie('SlideShow') == '' || getCookie('SlideShow') == 'true') {	
		setCookie('SlideShow','false');
		DD.slideshow.stop('dvContentSujets');
	} else if (getCookie('SlideShow') == 'false') {
		setCookie('SlideShow','true');
		DD.slideshow.start('dvContentSujets');
	} else {
		setCookie('SlideShow','false');
	}

	document.getElementById('slideShowControls').style.backgroundImage = 'url(/images/icons/ico_thumbnail_' + ( getCookie('SlideShow') == 'false' ? 'play' : 'stop' ) + 'gallery.gif)';
	document.getElementById('slideShowControl').innerHTML = 'Slide-Show ' + ( getCookie('SlideShow') == 'false' ? 'starten' : 'anhalten' );
}

function getCookie(c_name) {
	if (document.cookie.length>0) {
		c_start=document.cookie.indexOf(c_name + "=");
		if (c_start!=-1){
			c_start=c_start + c_name.length+1;
			c_end=document.cookie.indexOf(";",c_start);
			if (c_end==-1) c_end=document.cookie.length;
				return unescape(document.cookie.substring(c_start,c_end));
			} 
		}
	return "";
}

function setCookie(c_name,value,expiredays) {
	var exdate=new Date();
	exdate.setDate(exdate.getDate()+expiredays);
	document.cookie=c_name+ "=" +escape(value)+((expiredays==null) ? "" : ";expires="+exdate.toGMTString());
}