// Based on Form Validation
// by Paul Adams  and Apple Developer Connection
// http://www.oreillynet.com/pub/a/javascript/2001/08/10/form_valid.html?page=1

// Copyright © 2001 by Apple Computer, Inc., All Rights Reserved.
//
// You may incorporate this Apple sample code into your own code
// without restriction. This Apple sample code has been provided "AS IS"
// and the responsibility for its operation is yours. You may redistribute
// this code, but you are not permitted to redistribute it as
// "Apple sample code" after having made changes.

// non-empty textbox

function isEmpty(strng,errmsg) {
var error = "";
	if (strng.length == 0) {
		error = errmsg + "\n";
	}
return error;	  
}

// valid selector from dropdown list

function checkDropdown(choice,errmsg) {
var error = "";
	if (choice == 0) {
		error = errmsg + "\n";
	}    
return error;
}    
