6
8
function validate (form) {
10
13
// fullname: standard text, hidden, password, or textarea box
11
14
var fullname = form.elements['fullname'].value;
12
15
if (fullname == null || fullname === "") {
13
16
alertstr += '- Invalid entry for the "Full Name" field\n';
16
20
if (invalid > 0 || alertstr != '') {
17
21
if (! invalid) invalid = 'The following'; // catch for programmer error
18
22
alert(''+invalid+' error(s) were encountered with your submission:'+'\n\n'
19
23
+alertstr+'\n'+'Please correct these fields and try again.');
25
26
return true; // all checked ok