function navbarShow(aUrl){
	parent.content.location = aUrl;
}

function deleteItem(aUrl){
	// This functions pops up a confirmbox and redirects the browser
	// to the given URL if the user presses Yes.
	if(confirm("Weet u het zeker?")){
		document.location = aUrl;
	}
}

function isInArray(aArray, aVal){
	for(var i in aArray){
		if(aArray[i] == aVal){
			return true;
		}
	}
	return false;
}

function isNumeric(aString){
	// This funtion returns if the contents of a string are purely numbers
	var is_ok = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9");
	for(var i=0;i<aString.length;i++){
		if(!(isInArray(is_ok, aString.charAt(i)))){
			return false
		}
	}
	return true;
}

function validateMail(aMail){
	// This function checks if there are any occurences of "@" AND "."
	return ((aMail.indexOf("@") != -1) && (aMail.indexOf(".") != -1));
}

function openWindow(aUrl, aName, aWidth, aHeight, aScroll){
	// This function opens a window with the specified width and height.
	lArg = 'width='+aWidth+',height='+aHeight+',scrollbars='+aScroll;
	lWin = window.open(aUrl, aName, lArg);
	lWin.focus();
}
