1 2 3 //form validation 4 function validateName(fld) { 5 "use strict"; 6 var error = ""; 7 8 if (fld.value === '' || fld.value === 'Nickname' || fld.value === 'Enter Your Name..' || fld.value === 'Your Name..') { 9 error = "You didn't enter Your First Name.\n"; 10 } else if ((fld.value.length < 2) || (fld.value.length > 200)) { 11 error = "First Name is the wrong length.\n"; 12 } 13 return error; 14 } 15 16 function validateEmail(fld) { 17 "use strict"; 18 var error=""; 19 var illegalChars = /^[^@]+@[^@.]+\.[^@]*\w\w$/; 20 21 if (fld.value === "") { 22 error = "You didn't enter an email address.\n"; 23 } else if ( fld.value.match(illegalChars) === null) { 24 error = "The email address contains illegal characters.\n"; 25 } 26 27 return error; 28 29 } 30 31 function valName(text) { 32 "use strict"; 33 var error = ""; 34 35 if (text === '' || text === 'Nickname' || text === 'Enter Your Name..' || text === 'Your Name..') { 36 error = "You didn't enter Your First Name.\n"; 37 } else if ((text.length < 2) || (text.length > 50)) { 38 error = "First Name is the wrong length.\n"; 39 } 40 return error; 41 } 42 43 function valEmail(text) { 44 "use strict"; 45 var error=""; 46 var illegalChars = /^[^@]+@[^@.]+\.[^@]*\w\w$/; 47 48 if (text === "") { 49 error = "You didn't enter an email address.\n"; 50 } else if ( text.match(illegalChars) === null) { 51 error = "The email address contains illegal characters.\n"; 52 } 53 54 return error; 55 56 } 57 58 function validateMessage(fld) { 59 "use strict"; 60 var error = ""; 61 62 if (fld.value === '') { 63 error = "You didn't enter Your message.\n"; 64 } else if (fld.value.length < 3) { 65 error = "The message is to short.\n"; 66 } 67 68 return error; 69 } 70 71 function validatecheckbox() { 72 "use strict"; 73 var error = "Please select at least one checkbox!\n"; 74 return error; 75 } 76
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.