//Print mogelijkheid
function printPage(td) {
	if (document.getElementById(td)) {
		var inhoud = document.getElementById(td).innerHTML;
		if (document.getElementById('breadcrumbs')) {
			var breadcrumbs = document.getElementById('breadcrumbs').innerHTML;
			window.printgedeelte = '<table><tr><td id="breadcrumbs">'+breadcrumbs+'<br></td></tr><tr><td>'+inhoud+'</td></tr></table>';
		} else
			window.printgedeelte = '<table><tr><td>'+inhoud+'</td></tr></table>';
		var w = window.open('/print.html');
	}
}

//Leden module
function toon_groteafbeelding(afbeelding) {
	afbeelding.src = '/images/dot_clear.gif';
	afbeelding.style.border = '0';
}

function toon_spacer(afbeelding) {
	afbeelding.src = '/images/dot_clear.gif';
	afbeelding.style.width = '1px';
}

function setBorder(afbeelding) {
	var src = afbeelding.src;
	var temp = new Array();
	temp = src.split('/');

	if (typeof temp == 'object') {
		if (temp[4] !== 'dot_clear.gif')
			afbeelding.style.border = '1px solid #52813D';
	}
}

//Download bouwsteen
function toon_afbeelding_klein(afbeelding) {
	afbeelding.src='/images/not_available_klein.gif'
}
function toon_afbeelding_icon(afbeelding) {
	afbeelding.src='/images/not_available_icon.gif'
}

//koppel de juiste classes bij mouseover uitklapmenu
sfHover = function() {
	if (document.getElementById("navigatie")) {
		var sfEls = document.getElementById("navigatie").getElementsByTagName("LI");
		for (var i=0; i<sfEls.length; i++) {
			sfEls[i].onmouseover=function() {
				this.className+=" sfhover";
			}
			sfEls[i].onmouseout=function() {
				this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
			}
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

//benodigde functie voor foto overzichts bouwsteen
var InternetExplorer = navigator.appName.indexOf("Microsoft") != -1;
var popupscherm=0;

function popup_afbeelding(filename, fileid, width, height, scrollbars, resizable, menubar, toolbar, status, location) {
	if (popupscherm && ! popupscherm.closed)	popupscherm.close();
	if (!filename || filename=="")				filename="http://www.grundel.nl";
	if (!fileid || fileid=="")					fileid="Grundel";
	if (!width || width=="")					width="50";
	if (!height || height=="")					height="50";
	if (!scrollbars || scrollbars=="")			scrollbars="no";
	if (!resizable || resizable=="")			resizable="no";
	if (!menubar || menubar=="")				menubar="no";
	if (!toolbar || toolbar=="")				toolbar="no";
	if (!status || status=="")					status="no";
	if (!location || location=="")				location="no";
	popupscherm=0;
	var args = "height=" + height + ", width=" + width + ", scrollbars=" + scrollbars + ", resizable=" + resizable +  ", menubar=" + menubar + ", toolbar=" +toolbar + ", status=" + status + " ,location=" + location;
	popupscherm = open(filename, fileid, args);
	if (!InternetExplorer) 						popupscherm.focus();
}