mail\BaseMailer sendMultiple()

sendMultiple() public method Sends multiple messages at once. The default implementation simply calls send() multiple times. Child classes may override this method to implement more efficient way of sending multiple messages. public integer sendMultiple ( array $messages )$messages array List of email messages, which should be sent. return integer Number of messages that are successfully sent.

mail\BaseMailer getViewPath()

getViewPath() public method public string getViewPath ( )return string The directory that contains the view files for composing mail messages Defaults to '@app/mail'.

mail\BaseMailer render()

render() public method Renders the specified view with optional parameters and layout. The view will be rendered using the $view component. public string render ( $view, $params = [], $layout = false )$view string The view name or the path alias of the view file. $params array The parameters (name-value pairs) that will be extracted and made available in the view file. $layout string|boolean Layout view name or path alias. If false, no layout will be applied. return string The re

mail\BaseMailer saveMessage()

saveMessage() protected method Saves the message as a file under $fileTransportPath. protected boolean saveMessage ( $message )$message yii\mail\MessageInterface return boolean Whether the message is saved successfully

mail\BaseMailer getView()

getView() public method public yii\web\View getView ( )return yii\web\View View instance.

mail\BaseMailer EVENT_BEFORE_SEND

EVENT_BEFORE_SEND event of type yii\mail\MailEvent An event raised right before send. You may set yii\mail\MailEvent::$isValid to be false to cancel the send.

mail\BaseMailer EVENT_AFTER_SEND

EVENT_AFTER_SEND event of type yii\mail\MailEvent An event raised right after send.

mail\BaseMailer generateMessageFileName()

generateMessageFileName() public method public string generateMessageFileName ( )return string The file name for saving the message when $useFileTransport is true.

mail\BaseMailer beforeSend()

beforeSend() public method This method is invoked right before mail send. You may override this method to do last-minute preparation for the message. If you override this method, please make sure you call the parent implementation first. public boolean beforeSend ( $message )$message yii\mail\MessageInterface return boolean Whether to continue sending an email.

mail\BaseMailer compose()

compose() public method Creates a new message instance and optionally composes its body content via view rendering. public yii\mail\MessageInterface compose ( $view = null, array $params = [] )$view string|array|null The view to be used for rendering the message body. This can be: a string, which represents the view name or path alias for rendering the HTML body of the email. In this case, the text body will be generated by applying strip_tags() to the HTML body. an array with 'html' a