Tuesday, June 7, 2016

Drupal Rules - Sending to Multiple Emails

This one took me awhile, with a lot of interesting testing.

I had a Rule setup to email a user when a node went to a certain Workflow state. Easy enough.

myemail@example.com  works just fine!


To add a second email? Difficult. That's the part where you actually need to read the description in the TO section of the Action:
"The formatting of this string must comply with RFC 2822."

What's RFC 2822? No clue really, until I did some research. Read this if you want to know the whole RFC. https://tools.ietf.org/html/rfc2822#page-15

Based on Page 15 and looking at an email I had received through my GMail, I decided to try using the angle brackets. Here's what I got:

<myemail@example.com>, <jarod@example.com>

I re-ran the rule and received the email I was expecting. Jeepers!


No comments:

Post a Comment