var Url = window.location.hostname;
//document.writeln('<BASE HREF="http://' + Url + '">');

function hoverLink(id)
	{
		if(document.getElementById(id).style.color == '#ffff00')
			{
			document.getElementById(id).style.color = '#ffffff';
			}
		else
			{
			document.getElementById(id).style.color = '#ffff00';
			}
	}

function showHide(id)
{
	
	if (document.getElementById('div'+id).style.display == 'none')  //als hij dicht is...
		{
		document.getElementById('div'+id).style.display = 'block';  //zet open
		}
	else
		{
		document.getElementById('div'+id).style.display = 'none';  //maak dicht
		}
		
	if ((id != two) && (two != '')) // als id niet gelijk is aan vorige keuze
		{
		document.getElementById('div'+two).style.display = 'none';

		}
}

function getString(the_info)
{
		var newString = unescape(location.search.substring(1));
		var separated_values = newString.split('&');
	
		// loop through the list of name:values and load
		// up the associate array	
		var property_value = '';
	
		for (var loop = 0; loop < separated_values.length; loop++)
			{
			property_value = separated_values[loop];
			var broken_info = property_value.split('=');
			var the_property = broken_info[0];
			var the_value = broken_info[1];
			the_info[the_property] = the_value;
			}
}

var aktief = 'home';

if (location.search.length > 0)
{
	var string_information = new Array();
	getString(string_information);
	
	aktief = string_information['aktief'];

}


// onMouseOver functie voor hoofdmenu
function turn_on(id)
	{
	document.getElementById(id).src = 'images/menu/' + id + '_01.gif';
	}

// onMouseOut functie voor hoofdmenu met controle op huidige hoofdstuk.
// Het plaatje van het aktieve hoofdstuk moet namelijk niet terug naar de beginwaarde.
function turn_off(id)
	{
	if (id != aktief)
		{
		document.getElementById(id).src = 'images/menu/' + id + '_00.gif';
		}
	}


// schuifmenu

function schuifMenu(openDicht,id)
{

var hetMenu = document.getElementById(id + 'Drop');

var tussenWaarde1 = parseInt(hetMenu.style.height);
var tussenWaarde2 = tussenWaarde1 * 2;
var deTopWaarde = tussenWaarde1 - tussenWaarde2;

	if ((document.getElementById) && (openDicht == 1))
	{
		while (parseInt(hetMenu.style.top) < 100)
		{
		hetMenu.style.top = parseInt(hetMenu.style.top) + 1 + 'px';
		}
	}
	
	else if ((document.getElementById) && (openDicht == 0) && (id != aktief))
	//else if ((document.getElementById) && (openDicht == 0))
	{
		while (parseInt(hetMenu.style.top) > deTopWaarde)
		{
		hetMenu.style.top = parseInt(hetMenu.style.top) - 1 + 'px';
		}
		
	}
	
}




function herstelMenu()
	{
	if (aktief != '')
		{
		schuifMenu(1,aktief)
		document.getElementById(aktief).src = 'images/menu/' + aktief + '_01.gif';
		}
	}
