var oldElement = null;

function onSubMenu(element) {

	if (document.all) {
		element.firstChild.style.top = '19px';
	} else {
		element.firstChild.style.top = '16px';
	}

	if (element != null) {

		element.firstChild.nextSibling.style.color = '#3792CB';
		element.firstChild.nextSibling.style.backgroundColor = '#FFFFFF';
		element.firstChild.nextSibling.style.borderTop = '1px solid #CCCCCC';

		element.firstChild.style.visibility = 'visible';
		element.firstChild.style.display = 'inline';
	}

	oldElement = element;
}

function offSubMenu(element) {

	if (oldElement != null) {

		oldElement.firstChild.nextSibling.style.color = '#969696';
		oldElement.firstChild.nextSibling.style.backgroundColor = 'transparent';
		oldElement.firstChild.nextSibling.style.borderTop = 'none';

		oldElement.firstChild.style.visibility = 'hidden';
		oldElement.firstChild.style.display = 'none';
	}
}

function toggleSearchButton(element) {

	if (element.src == 'http://'+window.location.hostname+'/_img/bt_zoekOut.gif') {
		element.src = 'http://'+window.location.hostname+'/_img/bt_zoekOver.gif';
	} else {
		element.src = 'http://'+window.location.hostname+'/_img/bt_zoekOut.gif';
	}
}

function focusSearchField(element) {

	if (element.value == 'Zoek in weblog Independer')
		element.value = '';
}

function blurSearchField(element) {

	if (element.value == '')
		element.value = 'Zoek in weblog Independer';
}