Closed (outdated)
Project:
Flow (automation)
Component:
Code
Priority:
Major
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
23 Aug 2012 at 17:41 UTC
Updated:
19 Dec 2016 at 21:37 UTC
Jump to comment: Most recent
i have changed the user module as follows
$_SESSION['loginerror']='';// to store the login error
// change the following function
function user_login_final_validate($form, &$form_state) {
global $user;
if (!$user->uid) {
//form_set_error('name', t('Sorry,...); // comment this line
$_SESSION['loginerror']='error of pw wrong';
}
}
then create the block and add the following code
echo $_SESSION['loginerror'];
return drupal_get_form('user_login_block');
When i submit without password and username is show the $_SESSION['loginerror'] value "error of pw wrong" , when i enter the wrong user and wrong pass it does not show the value of session variable. can anybody help in this.
I want to overtake the drupal error and right my own with different format.
Comments
Comment #1
mxh commentedThis namespace is taken for a new project, see https://www.drupal.org/node/2833026.