I want to add an extra field for user age. If age is below 13, it should show another text input for getting mail address of user's parent or other legal guardian. Accounts with age under 13 should only be activated after email verification by said parent.

How can I add this field, validate age and process validation mail?

  • Are you sure you want it on login, not on registration? And why simply adding fields won't be enough for you?
    – Mołot
    Commented Nov 21, 2013 at 13:14
  • sorry..i want it in registration Commented Nov 21, 2013 at 13:27

1 Answer 1


Simply go to Home > Administration > Configuration > People > Account settings and add fields you need. Use Conditional Fields module to conditionally show a text box.

Now you need to use Rules. See registration rules post for example - what you want is to automatically enable account if checkbox is empty, and send email if checkbox is checked. How to do the very last thing, and how to process verification link, is a material for a separate question.

Questions that may help with further development a bit:

  • Now i finished conditional fields,now i want how to send mail ? Commented Nov 21, 2013 at 14:05
  • @vanapandi Play with the rules a bit. There is a rule called "User account has been created". And sending emails from rules is already described, like here and here. And then when you will have some basic grab on how this works, ask another question and we'll try to answer it :)
    – Mołot
    Commented Nov 21, 2013 at 14:10
  • Workflow » Rules » Editing reaction rule "Mail" -> in User identifier field giving error that was "User identifier must be an integer value."identifier value is "account:uid".is there anything went wrong? Commented Nov 21, 2013 at 14:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.