function logintoboggan_user_login_validate in LoginToboggan 5
Same name and namespace in other branches
- 8 logintoboggan.module \logintoboggan_user_login_validate()
- 6 logintoboggan.module \logintoboggan_user_login_validate()
- 7 logintoboggan.module \logintoboggan_user_login_validate()
Custom validation for user login form
File
- ./
logintoboggan.module, line 400 - Logintoboggan Module
Code
function logintoboggan_user_login_validate($form_id, $form_values, $form) {
if (isset($form_values['name'])) {
if ($name = db_result(db_query("SELECT name FROM {users} WHERE LOWER(mail) = LOWER('%s')", $form_values['name']))) {
form_set_value($form['name'], $name);
}
}
}