function WinOpenGen(url, breite, hoehe, sroll)
{
    Xkoord=(screen.width/2-(breite/2));
	Ykoord=(screen.height/2-(hoehe/2));
	params="resizable=1,status=0,scrollbars="+sroll+",toolbar=0,location=0,directories=0,menubar=0,width="+breite+",height="+hoehe+",left="+Xkoord+",top="+Ykoord;
	Fenster = window.open(url,"DisplayPopup",params);
	Fenster.focus();
}
function WinOpenGen2(url, breite, hoehe, sroll)
{
    Xkoord=(screen.width/2-(breite/2));
	Ykoord=(screen.height/2-(hoehe/2));
	params="resizable=1,status=0,scrollbars="+sroll+",toolbar=0,location=0,directories=0,menubar=0,width="+breite+",height="+hoehe+",left="+Xkoord+",top="+Ykoord;
	Fenster = window.open(url,"ShowGallery",params);
	Fenster.focus();
}
function WinOpenBuch(id_buch)
{
    Xkoord=(screen.width/2-(500/2));
	Ykoord=(screen.height/2-(400/2));
	params="resizable=1,status=0,scrollbars=0,toolbar=0,location=0,directories=0,menubar=0,width=500,height=400,left="+Xkoord+",top="+Ykoord;
	Fenster = window.open("/popup-buch.php?id_buch="+id_buch,"DisplayBook",params);
	Fenster.focus();
}
function zentriereWebseiteVertikal()
{
	var add = Ykoord=((screen.height-590)/2);
	document.getElementById('container').innerHTML = '<img src="/img/spacer.gif" alt="" width="1" height="'+add+'" border="0" />' + document.getElementById('container').innerHTML;
}
function submit_form(formular)
{
  document.forms[formular].submit();
}
function zeig(id)
{
	if (document.getElementById(id).style.display == "inline") 
	{
		document.getElementById(id).style.display = "none";
	}
	else 
	{
		document.getElementById(id).style.display = "inline";
	}
}
/*
Extension developed by David G. Miles (www.z3roadster.net/dreamweaver)
Original Scrollable Area code developed by Thomas Brattli 
To add more shock to your site, visit www.DHTML Shock.com
*/
function verifyCompatibleBrowser(){ 
    this.ver=navigator.appVersion 
    this.dom=document.getElementById?1:0 
    this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0; 
    this.ie4=(document.all && !this.dom)?1:0; 
    this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0; 
 
    this.ns4=(document.layers && !this.dom)?1:0; 
    this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5) 
    return this 
} 
bw=new verifyCompatibleBrowser() 
 
 
var speed=50 
 
var loop, timer 
 
function ConstructObject(obj,nest,obj_hoehe,layer_id) { 
    nest=(!nest) ? '':'document.'+nest+'.' 
    this.el=bw.dom?document.getElementById(obj):bw.ie4?document.all[obj]:bw.ns4?eval(nest+'document.'+obj):0; 
    this.css=bw.dom?document.getElementById(obj).style:bw.ie4?document.all[obj].style:bw.ns4?eval(nest+'document.'+obj):0; 
    this.scrollHeight=bw.ns4?this.css.document.height:this.el.offsetHeight 
    this.clipHeight=bw.ns4?this.css.clip.height:this.el.offsetHeight 
    this.up=MoveAreaUp;this.down=MoveAreaDown; 
    this.MoveArea=MoveArea; this.x; this.y; 
    this.obj = obj + "Object" 
    eval(this.obj + "=this") 
	if (obj_hoehe)
	{
		if (obj_hoehe < this.scrollHeight)
		{
			zeig(layer_id);
		}
	}
	return this
} 
function MoveArea(x,y){ 
    this.x=x;this.y=y 
    this.css.left=this.x 
    this.css.top=this.y 
} 
 
function MoveAreaDown(move){ 
	if(this.y>-this.scrollHeight+objContainer.clipHeight){ 
    this.MoveArea(0,this.y-move) 
    if(loop) setTimeout(this.obj+".down("+move+")",speed) 
	} 
} 
function MoveAreaUp(move){ 
	if(this.y<0){ 
    this.MoveArea(0,this.y-move) 
    if(loop) setTimeout(this.obj+".up("+move+")",speed) 
	} 
} 
 
function PerformScroll(speed){ 
	if(initialised){ 
		loop=true; 
		if(speed>0) objScroller.down(speed) 
		else objScroller.up(speed) 
	} 
}
function CeaseScroll(){ 
    loop=false 
    if(timer) clearTimeout(timer) 
} 
function PerformScroll2(speed){ 
	if(initialised2){ 
		loop=true; 
		if(speed>0) objScroller2.down(speed) 
		else objScroller2.up(speed) 
	} 
}
function CeaseScroll2(){ 
    loop=false 
    if(timer) clearTimeout(timer) 
} 

var initialised;
var initialised2;
function InitialiseScrollableArea1()
{
	objContainer=new ConstructObject('veranstaltungenContainer');
    objScroller=new ConstructObject('veranstaltungen','veranstaltungenContainer', 400, 'veranstaltungenScroll');
    objScroller.MoveArea(0,1);
    objContainer.css.visibility='visible';
    initialised=true;
} 
function InitialiseScrollableArea2()
{ 
    objContainer2=new ConstructObject('neuBABContainer');
    objScroller2=new ConstructObject('neuBAB','neuBABContainer',400, 'neuBABScroll');
    objScroller2.MoveArea(0,0);
    objContainer2.css.visibility='visible';
    initialised2=true;
}
function InitialiseScrollableArea3()
{ 
    objContainer=new ConstructObject('popupContainer');
    objScroller=new ConstructObject('popup','popupContainer',370, 'popupScroll');
    objScroller.MoveArea(0,0);
    objContainer.css.visibility='visible';
    initialised=true;
}
function InitialiseScrollableArea4()
{
    objContainer=new ConstructObject('popupContainer');
    objScroller=new ConstructObject('popup','popupContainer',370, 'popupScroll');
    objScroller.MoveArea(0,0);
    objContainer.css.visibility='visible';
    initialised=true;
} 
// end absolutely positioned scrollable area object scripts 