Problem/Motivation

Currently, this module only supports one address as a 'TO' address. Drupal core and PHPMailer both support multiple 'TO' addresses. This issue seeks to extend Just SMTP to support multiple 'TO' addresses.

Currently, when a user tries to submit a comma-separated string of addresses, s/he will receive the following error:

The submitted to address (chris@example.net, chris@example.com) is not valid.

Proposed resolution

Drupal core supports multiple 'TO' addresses by storing them in a comma-separated string. PHPMailer allows for $this->addAddress() to be called multiple times per message. The proposed solution is to convert the string into an array, and then iterate through it, calling addAddress() for each address.

Remaining tasks

Submit patch for review
Community review

User interface changes

None

API changes

None

Data model changes

None

Comments

Chris Burge created an issue. See original summary.

chris burge’s picture

Issue summary: View changes
Status: Active » Needs review
StatusFileSize
new1.88 KB
chris burge’s picture

StatusFileSize
new1.88 KB

New patch that 1) corrects the drupal_set_message and watchdog messages and 2) checks $to['mail'] with valid_email_address() instead of $address.

keshavv’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new23.11 KB

Patch applied cleanly and working perfectoutput

berenddeboer’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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