MediaWiki  master
MediaWiki\Mail\Emailer Class Reference
Inheritance diagram for MediaWiki\Mail\Emailer:
Collaboration diagram for MediaWiki\Mail\Emailer:

Public Member Functions

 send (array $to, MailAddress $from, string $subject, string $bodyText, ?string $bodyHtml=null, array $options=[])
 

Detailed Description

Definition at line 31 of file Emailer.php.

Member Function Documentation

◆ send()

MediaWiki\Mail\Emailer::send ( array  $to,
MailAddress  $from,
string  $subject,
string  $bodyText,
?string  $bodyHtml = null,
array  $options = [] 
)
Since
1.35

This function will perform a direct (authenticated) login to a SMTP Server to use for mail relaying if 'wgSMTP' specifies an array of parameters. It requires PEAR:Mail to do that. Otherwise it just uses the standard PHP 'mail' function.

Sends emails to recipients.

Since
1.35
Parameters
MailAddress[]$toArray of Recipients' emails
MailAddress$fromSender's email
string$subjectEmail's subject.
string$bodyTexttext part of body
string | null$bodyHtmlhtml part of body (optional)
array$optionsKeys: 'replyTo' MailAddress 'contentType' string default 'text/plain; charset=UTF-8' 'headers' array Extra headers to set

-param array{replyTo?:MailAddress,contentType?:string,headers?:array<string,string>} $options

Exceptions
MWException
Exception
Returns
StatusValue

Implements MediaWiki\Mail\IEmailer.

Definition at line 43 of file Emailer.php.

References UserMailer\send().


The documentation for this class was generated from the following file: