
function MM_findObj(n, d) { //v3.0
var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}
/* Functions that swaps images. */
function MM_swapImage() { //v3.0
var layer1,i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
;
}
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function confirmLink( theLink, msg) {
	var is_confirmed = confirm(msg);
	if (is_confirmed) {
		theLink.href += '&confirmed=1';
	}
	return is_confirmed;
}

function popwindow(size,url,align) {
	var wWidth, wHeight, wLeft, wTop;
	wWidth = size*100;
	wHeight = wWidth*.75;
	if(align=='center') {
		wLeft = (screen.width-wWidth)/2;
		wTop = (screen.height-wHeight)/2;
		var Scherm = window.open(url, '_blank', 'scrollbars=yes,width='+wWidth+',height='+wHeight+',left='+wLeft+',top='+wTop);
	} else {
		var Scherm = window.open(url, '_blank', 'scrollbars=yes,width='+wWidth+',height='+wHeight);
	}
	Scherm.focus();
}

function popwindowXY(wWidth,wHeight,url,align) {
	var wLeft, wTop;
	if(align=='center') {
		wLeft = (screen.width-wWidth)/2;
		wTop = (screen.height-wHeight)/2;
		var Scherm = window.open(url, '_blank', 'scrollbars=yes,width='+wWidth+',height='+wHeight+',left='+wLeft+',top='+wTop);
	} else {
		var Scherm = window.open(url, '_blank', 'scrollbars=yes,width='+wWidth+',height='+wHeight);
	}
	Scherm.focus();
}

function terug() {
	if(document.getElementById('inhoud').offsetHeight>500) {
		document.getElementById('naarboven').style.visibility='visible';
	}
}

function setHgt() {
	OBJ1=document.getElementById('left');
	OBJ2=document.getElementById('content');
	OBJ3=document.getElementById('top');
	OBJ4=document.getElementById('footer');
	H=Math.max(OBJ1.offsetHeight,OBJ2.offsetHeight,document.body.offsetHeight);
	L=H-OBJ4.offsetHeight;
	C=H-OBJ3.offsetHeight-OBJ4.offsetHeight;
	if(OBJ1.offsetHeight<L && OBJ2.offsetHeight<C) {
		OBJ1.style.height=L+'px';
		OBJ2.style.height=C+'px';
	} else {
		L=OBJ2.offsetHeight+OBJ3.offsetHeight;
		OBJ1.style.height=L+'px';
	}
}


window.onload=setHgt;
window.onscroll=terug;