I used the drupal example email module (email_example) found here: http://drupal.org/project/examples
I'd like to email multiple recipients and according to http://api.drupal.org/api/drupal/includes!mail.inc/function/drupal_mail/6:
$to: The e-mail address or addresses where the message will be sent to. The formatting of this string must comply with RFC 2822. Some examples are: [email protected] [email protected], [email protected] User User , Another User
HOWEVER. When I try to modify $to in function email_example_mail_send($form_values) {
I am not able to add multiple addresses.
either
$to = "[email protected]";
$to = $form_values['email1'];
work,
but
$to = "[email protected]", "[email protected]";
or
$to = $form_values['email1'], $form_values['email2'] ;
do not.