CC addresses are added as BCC

chuckdeal97 - March 25, 2009 - 14:01
Project:SMTP Authentication Support
Version:6.x-1.0-beta3
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

In my messages I added a CC address

$message['headers']['CC'] = $ccaddr;

Both the From and CC user received the mail, but the CC user didn't show up as a CC. When I checked the code, both CC and BCC are being adding to the PHPMailer as a BCC.

I believe line 435 of smtp.module should become

          $mail->AddCC($ccaddr, $ccname);

Making that one line change fixed the problem for me.

#1

Mike_Waters - October 4, 2009 - 03:17

Seconded.

This is more critical than you might think, because of this:
[class.phpmailer.php; line 376.]

   * Adds a "Bcc" address.
   * Note: this function works with the SMTP mailer on win32, not with the "mail" mailer.
  public function AddBCC($address, $name = '') {

Because of this one line, neither CC nor BCC are possible on a *nix box.

 
 

Drupal is a registered trademark of Dries Buytaert.