	//  Default browsercheck
	function browserCheck(){
		this.ver=navigator.appVersion
		this.agent=navigator.userAgent
		this.dom=document.getElementById?1:0
		this.opera5=this.agent.indexOf("Opera 5")>-1
		this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom && !this.opera5)?1:0; 
		this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom && !this.opera5)?1:0;
		this.ie4=(document.all && !this.dom && !this.opera5)?1:0;
		this.ie=this.ie4||this.ie5||this.ie6
		this.mac=this.agent.indexOf("Mac")>-1
		this.ns6=(this.dom && parseInt(this.ver) >= 5) ?1:0; 
		this.ns4=(document.layers && !this.dom)?1:0;
		this.bw=(this.ie6 || this.ie5 || this.ie4 || this.ns4 || this.ns6 || this.opera5)
		return this
	}
	var bw=new browserCheck()
	
/**********************************************************************************   
* Fix mouseclick (onfocus)                                                        *
***********************************************************************************/
window.onload = function() {
	if(document.layers) return;
	if(document.getElementById) links = document.getElementsByTagName("A");
	if(document.all) links = document.all.tags("A");
		for(a = 0; a < links.length; a++) links[a].onfocus = new Function('this.blur()');
}

/**********************************************************************************   
* open Popup-windows                                                              *
***********************************************************************************/
var w = screen.availWidth;
var h = screen.availHeight;
var popW = 800, popH = 600;
var leftPos = (w-popW)/2, topPos = (h-popH)/2;

function popup(file) {
open(file,'window','width=' + popW + ',height=' + popH + ',top=' + topPos + ',left=' + leftPos +',toolbar=0,directories=0,status=0,menubar=0,resizable=0,scrollbars=1');
}
/**********************************************************************************   
* Open Popup-windows (2)														  *
*																				  *
* Met deze functie kan je zelf bepalen hoe groot de popup moet worden. 			  *
* B.V. <a href="#" onlclick="popup2('test.htm','windowname',640,480)">link</a>.   *
* In dit voorbeeld wordt een popup geopend van 640x480 met als inhoud 'test.htm'. *  
* Gebruik per afmeting een andere windownaam, anders wordt de pagina in de        *
* eventuele openstaande popup geopend met andere afmetingen.			          *	
***********************************************************************************/
function popup2(file,popName,popW,popH) {
	var w = screen.availWidth;
	var h = screen.availHeight;
	var popW, popH;
	var leftPos = (w-popW)/2, topPos = (h-popH)/2;

	open(file,popName,'width=' + popW + ',height=' + popH + ',top=' + topPos + ',left=' + leftPos +',toolbar=0,directories=0,status=0,menubar=0,resizable=1,scrollbars=1');
}
/**********************************************************************************   
* show hide scripts                                                               *
***********************************************************************************/
//showhide
function showhide(div,nest){
	obj=document.getElementById?document.getElementById(div).style:document.all?document.all[div].style:document.layers?nest?document[nest].document[div]:document[div]:0; 
	if(obj.visibility=='visible' || obj.visibility=='show') obj.visibility='hidden'
	else obj.visibility='visible'
}
//show
function show(div,nest){
	obj=document.getElementById?document.getElementById(div).style:document.all?document.all[div].style:document.layers?nest?document[nest].document[div]:document[div]:0; 
	obj.visibility='visible'
}
//hide
function hide(div,nest){
	obj=document.getElementById?document.getElementById(div).style:document.all?document.all[div].style:document.layers?nest?document[nest].document[div]:document[div]:0; 
	obj.visibility='hidden'
}  
/**********************************************************************************   
* show/hide script met timeout voor b.v. popup-menu's                             *
* code in link:                                                                   *
* <a href="#" onmouseover="clearTimeout(check);                                   *
*             onmouseout="showhide('[naam layer]');"                              *
***********************************************************************************/
var objT;
var check=0;
var iTimeOut = 0;

function showhide(div,nest){
	objT=bw.dom?"document.getElementById('"+div+"').style":bw.ie4?"document.all['"+div+"'].style":bw.ns4?nest?"document['"+nest+"'].document.layers['"+div+"']":"document.layers['"+div+"']":0; 
	obj = eval(objT);
	if(obj.visibility=='visible' || obj.visibility=='show'){
		check = setTimeout(objT+".visibility='hidden';",iTimeOut);
	}else{
		obj.visibility='visible';
	}
}	
	
/**********************************************************************************   
* Mouseover script / preload-images staan onderaan                                *
* (zet dit script in een aparte .js pagina, zodat de preload images               *
* niet steeds wordt ingeladen op pagina's waar het niet hoeft).                   *
***********************************************************************************/
function activateReset(){
	if (active != 0){
		checkImg(active,sDiv,0);
		active = 0;
	}
}
	
function activateUnIndi(a,sDiv){
	if (active != a){
		checkImg(a,sDiv,0);
	}else{
		checkImg(a,sDiv,2);
	}
}

function activateUnIndiTimer(a,sDiv){
	if (active != a){
		checkImg(a,sDiv,0);
	}else{
		checkImg(a,sDiv,2);
	}
}

function activateIndi(a,sDiv){
	if (active != a){
		checkImg(a,sDiv,1);
	}else{
		checkImg(a,sDiv,3);
	}
}

function activateClick(a,sDiv){
	checkImg(a,sDiv,3);
	if ((active != a) && (active != 0))	checkImg(active,sDiv,0);
	active = a; 
}

//verander de prefix van de naam als dat moet, dus als je bv. 'knop_home_off.gif' hebt dan moet je de prefix 'button_' hieronder aanpassen in 'knop_'
function preloadImg(a,sOff,sO,sK,sKO,sName){
	Indi[a]=new Array();
	for(var i=0;i<4;i++) Indi[a][i] = new Image;
	Indi[a][0].src = imgDir + "button_" + sName + "_" + sOff + imgExt;
	Indi[a][1].src = imgDir + "button_" + sName + "_" + sO + imgExt;
	Indi[a][2].src = imgDir + "button_" + sName + "_" + sK + imgExt;
	Indi[a][3].src = imgDir + "button_" + sName + "_" + sKO + imgExt;
}
function checkImg(a,sDiv,iType){
	if(document.layers){
		sDiv?document[sDiv].document['Indi' + a].src = Indi[a][iType].src:document['Indi' + a].src = Indi[a][iType].src;
	}else{
		document['Indi' + a].src = Indi[a][iType].src;
	}
}

// Preload-images
var Indi = new Array();
var imgDir = "img/";
var imgExt = ".gif";
active = 0;
timer_id = null;

// Preload-images
//  plaatjes,id,off,mouseover,klick,klickover,filename
preloadImg(1,"off","on","on","on","home");
preloadImg(2,"off","on","on","on","news");
preloadImg(3,"off","on","on","on","links");