4

Potential scenario:

Allow users with a particular email address or token to skip the admin approval step and have their account approved ie: it sends the password/login link out immediately and they don't receive the awaiting approval email.

All other users with other email addresses need to be approved by an admin.

One potential solution I've thought of is to act on hook_user_insert to unblock and send the password email the user hook_mail_alter to disable the initial awaiting approval email.

I just feel this option is a bit hacky and I'm wondering if there is a better way of doing things.

2

Take a look at User Restrictions module for Drupal 7 and Access Rules for Drupal 6.

UPDATE

For registering users based on unique code check out regcode module

| improve this answer | |

Your Answer

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

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