public function DrupalPHPMailer::Reset in PHPMailer 6.3
Same name and namespace in other branches
- 5.2 includes/phpmailer.class.inc \DrupalPHPMailer::Reset()
- 6 includes/phpmailer.inc \DrupalPHPMailer::Reset()
- 6.2 includes/phpmailer.class.inc \DrupalPHPMailer::Reset()
- 7.4 includes/phpmailer.class.inc \DrupalPHPMailer::Reset()
- 7.3 includes/phpmailer.class.inc \DrupalPHPMailer::Reset()
(Re-)initialize properties after sending mail.
2 calls to DrupalPHPMailer::Reset()
- DrupalPHPMailer::SmtpSend in includes/
phpmailer.class.inc - Send mail via SMTP.
- DrupalPHPMailer::__construct in includes/
phpmailer.class.inc - Constructor.
File
- includes/
phpmailer.class.inc, line 126 - Implements the base PHPMailer for Drupal class.
Class
- DrupalPHPMailer
- Base PHPMailer for Drupal implementation with support for SMTP keep-alive and setting a custom Return-Path.
Code
public function Reset() {
$this
->ClearAllRecipients();
$this
->ClearReplyTos();
$this
->ClearAttachments();
$this
->ClearCustomHeaders();
$this->Priority = 3;
$this->CharSet = variable_get('smtp_charset', 'utf-8');
$this->ContentType = 'text/plain';
$this->Encoding = '8bit';
// Set default From name.
$from_name = variable_get('smtp_fromname', '');
if ($from_name == '') {
// Fall back on the site name.
$from_name = variable_get('site_name', 'Drupal');
}
$this->FromName = $from_name;
$this->Sender = '';
$this->MessageID = '';
$this->ReturnPath = '';
}