I'm building a membership-based association site that uses Ubercart to assign roles to users who purchase a membership. I'm using the User Import module to create all of the existing association members as users on the Drupal site. Using views I've created a membership directory. It's important for testing purposes that these existing members' accounts are created first then become notified by email to log in at a later date.

My question: is it possible with views bulk operations to take 50 users who have never logged in and send them all their own account login emails?

Thanks,

Geoff

Comments

infojunkie’s picture

You can try to generate an email that is a replica of the standard Drupal account login email. To do this, you can try the "Send tokenized email" action that comes with Token module. The recipient would be the [mail] and the body would use the various available user tokens.

gpiersol’s picture

Thanks for your reply. I've been able to accomplish a lot of functions following your suggestions but I don't seem to be able to replicate the standard Drupal account login email with the "Send tokenized email" action that comes with Token i.e. there's no token for the one-time login URL or the user password. I suppose this is outside the realm of VBO now, so I'll see if I can find an answer elsewhere.

infojunkie’s picture

Status: Active » Fixed

I doubt you'd be able to find the password token, since the password itself is never stored cleartext in the database. Not sure about the one-time login URL, but creating your own tokens is just a matter of implementing a couple of hooks (hook_token_list and hook_token_values). Good luck.

kari.kaariainen’s picture

If I'm not mistaken, Drupal sends the Account activation email to a never-logged-in user when the account is activated. You can activate a user either at admin/user/user (Unblock the selected users) or in VBO when you have a view of User type and you have enabled the operation Unblock the selected users (user_user_operations_unblock) in Basic settings - Style - Bulk operations - Style options. This email can be fully edited at admin/user/settings. There is also a check box to control sending the email.

If you made those users active (unblocked) for testing purposes when you originally imported them, just block them first and then unblock them. Don't worry, blocking won't send them anything by default. There is a check box to control that too at admin/user/settings.

gpiersol’s picture

Thanks so much for your reply! I don't know why I didn't think of the block/unblock method- it makes a lot of sense now.

I ended up installing the One-time login links module, which is useful in its own ways, but your method seems to be much better for the purposes of my original support request.

Cheers!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.