--- validateage_with_patch_391884.module 2009-10-24 12:37:12.000000000 +0200 +++ validateage.module 2009-10-24 13:20:22.000000000 +0200 @@ -152,10 +152,16 @@ $age = _validateage_get_age($birthday); $minimum_age = variable_get('validateage_age', '18'); if ($age < $minimum_age) { - if($GLOBALS['user']->uid) - form_set_error('', t('Please contact the administrator to change your birthday.')); + if($GLOBALS['user']->uid) + form_set_error('', t('Please contact the administrator to change your birthday.')); + else { + if ($age < 1) + // User didn't set date at all or chose current year's birthday + form_set_error('', t('Please indicate your date of birth.')); else + // User is underaged, suggested (not blatant) message reduces probability to trigger lie form_set_error('', t(variable_get('validateage_fail_message', 'Sorry, we are unable to accept your registration at this time.'))); + } } elseif (_validateage_check_birthday($birthday)) { drupal_set_message(t('Happy Birthday!'));