array_push($formErrors, '{--SPONSOR_PASSWORD2_EMPTY--}');
}
}
- } elseif (strlen(postRequestElement('password1')) < getPassLen()) {
+ } elseif (strlen(postRequestElement('password1')) < getMinPasswordLength()) {
// Password is to short!
array_push($formErrors, '{--SPONSOR_PASSWORD_TOO_SHORT--}');
}
} // END - if
// If there is something wrong/missing stop registration
- if (count($formErrors) > 0) unsetPostRequestElement('ok');
+ if (isFilledArray($formErrors)) unsetPostRequestElement('ok');
} // END - if
-if ((isFormSent()) && (count($formErrors) == 0)) {
+if ((isFormSent()) && (!isFilledArray($formErrors))) {
// Generate message array
$messageArray = array(
'failed' => '{--SPONSOR_REGISTRATION_FAILED--}',
} // END - foreach
// Check for invalid entries
- if (count($formErrors) > 0) {
+ if (isFilledArray($formErrors)) {
// Some found... :-(
foreach (array('company','position','tax_ident','surname','family','street_nr1','street_nr2','country','zip','city','phone','fax','cell','email','url') as $entry) {
$content[$entry] = postRequestElement($entry);
$OUT = '';
// Errors found?
- if (count($formErrors) > 0) {
+ if (isFilledArray($formErrors)) {
$OUT = displayMessage('{--SPONSOR_REGISTER_SOMETHING_MISSING--}', TRUE);
$OUT .= '<ol>';
foreach ($formErrors as $error) {