class MailMessage (View source)

The MailMessage class.

Methods

__construct(string $subject = null, array $content = null, bool $html = true)

MailMessage constructor.

subject(string $subject)

subject

to(string $email, string $name = null)

to

from(string $email, string $name = null)

from

cc(string $email, string $name = null)

cc

bcc(string $email, string $name = null)

bcc

body(string $body, bool $html = null)

content

html(boolean $bool)

html

attach(string $file, string $name = null, string $type = null)

from

renderBody(string $layout, array $data = array(), string|RendererInterface $engine = null, string|AbstractPackage $package = null, string $prefix = 'mail')

renderBody

string
getSubject()

Method to get property Subject

array
getTo()

Method to get property To

array
getFrom()

Method to get property From

array
getCc()

Method to get property Cc

array
getBcc()

Method to get property Bcc

string
getBody()

Method to get property Content

boolean
getHtml()

Method to get property Html

getFiles()

Method to get property Files

Details

at line line 85
__construct(string $subject = null, array $content = null, bool $html = true)

MailMessage constructor.

Parameters

string $subject
array $content
bool $html

at line line 99
MailMessage subject(string $subject)

subject

Parameters

string $subject

Return Value

MailMessage

at line line 114
MailMessage to(string $email, string $name = null)

to

Parameters

string $email
string $name

Return Value

MailMessage

at line line 129
MailMessage from(string $email, string $name = null)

from

Parameters

string $email
string $name

Return Value

MailMessage

at line line 144
MailMessage cc(string $email, string $name = null)

cc

Parameters

string $email
string $name

Return Value

MailMessage

at line line 159
MailMessage bcc(string $email, string $name = null)

bcc

Parameters

string $email
string $name

Return Value

MailMessage

at line line 174
MailMessage body(string $body, bool $html = null)

content

Parameters

string $body
bool $html

Return Value

MailMessage

at line line 193
MailMessage html(boolean $bool)

html

Parameters

boolean $bool

Return Value

MailMessage

at line line 209
MailMessage attach(string $file, string $name = null, string $type = null)

from

Parameters

string $file
string $name
string $type

Return Value

MailMessage

at line line 242
MailMessage renderBody(string $layout, array $data = array(), string|RendererInterface $engine = null, string|AbstractPackage $package = null, string $prefix = 'mail')

renderBody

Parameters

string $layout
array $data
string|RendererInterface $engine
string|AbstractPackage $package
string $prefix

Return Value

MailMessage

at line line 257
string getSubject()

Method to get property Subject

Return Value

string

at line line 267
array getTo()

Method to get property To

Return Value

array

at line line 277
array getFrom()

Method to get property From

Return Value

array

at line line 287
array getCc()

Method to get property Cc

Return Value

array

at line line 297
array getBcc()

Method to get property Bcc

Return Value

array

at line line 307
string getBody()

Method to get property Content

Return Value

string

at line line 317
boolean getHtml()

Method to get property Html

Return Value

boolean

at line line 327
MailAttachment[] getFiles()

Method to get property Files

Return Value

MailAttachment[]