
//
// Script JavaScript for support of the NEDBIB list
// henk.matheezing.
// edited and extended by arno reuser a@reuser.biz
// 2jan08
//


function Bijgewerkt (Editor) {
	var d=document 							;
	d.write ("<pre>        </pre>") ;
	d.write ("<div align=\"right\" class='Edited'>	")		;
	d.write ("last edited " + Editor + " ")	;
	d.write (document.lastModified) 		;
	d.write ("</div>") 					;
}



function check(formulier) {


	var Keuze	= "(geen)" ;
	var Box		= formulier._message ;
	var Keuze	= Box.options[Box.selectedIndex].text ;

		// Set a _keuze field so we can send the client a decent mail
		// with the original order later
	formulier._keuze.value = Keuze ;

		// Check if the client has filled in a name
		// return if not
		//
	if (formulier._name.value=="") {
	  alert ("Vul alstublieft uw voornaam en achternaam in.")	;
	  return false;
	}

		// Check if the client has filled in a mail address
		// return if not
		//
	if (formulier._from.value=="") {
	  alert ("Vul alstublieft uw e-mail adres in.") ;
	  return false ;
	}

		// Check if the client has chosen a order to send.
		// return if not
		//
	if (Keuze=="") {
	  alert ("Kies alstublieft een opdracht die uitgevoerd moet worden. ") ;
	  return false ;
	}

		// check if the client has chosen a valid order, i.e. one that starts
		// with a hyphen. The other 'options' are not orders but headers
		// or empty lines for readability
		// 
	if (Keuze.substr(0,2) != "- ") {
		alert ('"' + Keuze + '" is helaas geen geldige opdracht. Een geldige opdracht begint met een liggend streepje. Kies alstublieft een geldige opdracht. ') ;
		return false;
	}


	//formulier.message.value = formulier._message.value;
	//if (formulier.message.value=="subscribe NEDBIB-L") {
	//  formulier.message.value="subscribe NEDBIB-L" + " " + formulier._name.value;
	//}

	return true;

}


