In this video, I will demonstrate LoginToboggan's Rules integration by showing you how to automatically send a welcome email to users after they validate their account using the Rules module.
Install modules
- Rules
- Entity API (Rules depends on this module)
Enable modules
- Go to "Modules" (admin/modules) and enable:
- Entity API
- Entity Tokens
- LoginToboggan Rules Integration
- Rules
- Rules UI
- (Save configuration)
Now, we can configure the message using Rules.
- Go to "Configuration => Workflow => rules" (config/workflow/rules)
- Click "Add new rule" link
- Name: Welcome Email For Validated Accounts
- React on event: choose "When the user account is validated"
- (Save)
- Actions
- Click "Add action"
- Select the action to add: Choose "Send mail" under system
- To
- Click the "Switch to data selection" button
- Data selector: account:mail
- Subject:
- Value: User account [account:name] is now [account:status].
- Message
- Value: Welcome! Now that your account has been validated, you have access to all this cool stuff!
- From
- Leave empty to use the site-wide configured address.
- (Save)
Let's validate one of our new accounts to try it out!
Once we've validated our account, we can check our email and we'll see the new message with all of the helpful information we need to know about the site.