//preload images
image0 = new Image(60,40);
image0.src = "images/english_language_flag.gif";
image1 = new Image(60,40);
image1.src = "images/dutch_language_flag.gif";

function show(id) {
	document.getElementById(id).style.visibility = 'visible';
}

function hide(id) {
	document.getElementById(id).style.visibility = 'hidden';
}

function menublockmouse(nbr, page) {
	str2write = '<div class="menu'+nbr+'" onmouseover="this.className=\'mouse\', show(\'mouse'+nbr+'\')" onmouseout="this.className=\'menu'+nbr+'\', hide(\'mouse'+nbr+'\')" onclick="javascript:(window.location=\''+page+'\');"></div>\n';
	document.write(str2write);
}

function menublocktitle(nbr,atxt) {
	str2write = '<span id="mouse'+nbr+'" class="mouse1">&nbsp;'+atxt+'</span>';
	document.write(str2write);
}

function writemenu(title) {
	lang = document.getElementsByTagName('html')[0].lang;
	menutxt = 'Menu, kies een blok.';
	menu = new Array('index.htm','Welkom','voorwie.htm','Voor wie','creabeg.htm','Creatieve begeleiding','focussen.htm','Focussen','curswork.htm','Cursussen en workshops','trkfment.htm','Training Kinderfocussen &amp; mentoring','focopl.htm','Focus-opleiding','aanbod.htm','Aanbod 2012','rene.htm','Ren&eacute;&nbsp;Veugelers','contact.htm','Contact');
	if (lang == 'en') {
		menutxt = 'Menu, choose an item.';
		menu = new Array('index_en.htm','Welcome','focusing.htm','Focusing','focuschild.htm','Focusing with Children','creasymb.htm','Creativity and Symbolization','childfocustraining.htm','Children Focusing training','childfocushistory.htm','Children Focusing history','offers.htm','Offers','reviews.htm','Reviews of other trainings + pictures','background.htm','Background of Ren&eacute; Veugelers','contact_en.htm','Contact');
	}
	i = 0;
	j = menu.length/2;
	document.write('<div class="naam"><img src="images/logo_name.jpg"></div>');
	document.write('<div class="menu-body">');
	for (i = 0; i < j; i++) {menublockmouse(''+(i+1),menu[i*2]);}
	document.write('</div><div class="menu-det"><div class="title"><h1>'+title+'</h1></div>');
	document.write('<span class="mouse2">'+menutxt+'</span>');
	for (i = 0; i < j; i++) {menublocktitle(''+(i+1),menu[i*2+1]);}
	document.write('</div>');
}

function writeside() {
	document.write('<div class="side"><div class="logo1">');
	document.write('<img src="images/logo_main1.jpg" width="124" height="154" alt="" title="Logo FTCZ">');
	document.write('</div><div class="logo2">');
	document.write('<img src="images/logo_main2.jpg" width="26" height="154" alt="" title="Logo FTCZ">');
	document.write('</div>');
	document.write('</div>');
}

