function openVenster(link) {
          	var venster, hoogte, ypos;
			if (document.all) { // IE
          			ypos = 0;
          			hoogte = screen.height - 80;
           		} else { // NS
          			ypos = 0;
          			hoogte = screen.height - 77;
          		}
	          	if (venster) {
        	  		venster.close();	// nog openstaand venster wordt gesloten
          		}
			var xpos, attributes;
			xpos = 138; 
			attributes = "status,height=" + hoogte + ",width=650,left=" + xpos + ",top=" + ypos ;
			attributes = attributes + ",screenX=" + xpos + ",screenY=" + ypos + ",scrollbars,resizable";
          		venster = window.open(link,"inschrijving",attributes);
			venster.focus();
}

function checkForm() { 
		  	//var melding = "Wakker blijven!\n";
			var fout = false;
		
			if (document.form1.LoginNaam.value == "") {
				alert('Je gebruikersnaam is niet ingevuld.');
				document.form1.LoginNaam.focus();
				fout = true;
				return false;
			}
		
			if (document.form1.Wachtwoord.value == "") {
				alert('Je wachtwoord is niet ingevuld.');
				document.form1.Wachtwoord.focus();
				fout = true;
				return false;
			}
				
			if (!fout) {
				openVenster("opgave/index.asp")
				document.form1.action = "opgave/login.asp";
				document.form1.method = "POST";
				document.form1.target = "inschrijving";
				document.form1.submit();
				document.form1.LoginNaam.value = "";
				document.form1.Wachtwoord.value = "";
				return false;
			}
			
			return false;
}


		