0

I am using Drupal 7. When ever I visit site.com/user/login I could see my Login form, thats fine. But when I miss to enter any fields say name and click the login button it does not shows the validation error message. Does any one what the actal problem might be?

Thanks

  • try the same thing with the default theme in drupal. it might be something theme related. if not, you may overrided the validation callback somehow. you can try disabling custom/contrib modules just in case some of them are doing something wrong... – Marius Ilie Aug 15 '12 at 22:57
2

Look at the form id for login form. and then try hook_form_alter() in any custom module.

Add a submit callback or validation callback in which you can check for the empty fields yourself. According use drupal_set_message() to display the error message.

  • Thanks for the reply piyuesh. Will give a try and let you know. – user4081 Jul 16 '12 at 10:10
-1

You can make use of a custom validation in the form alter and try to implement things all by your self.

  • May I know how this can be achieved? By the way thanks for the swift reply:) – user4081 Jul 16 '12 at 9:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy