Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
attachmentsFormData example
$this
->
addressesFormData
(
$fields
, 'replyto',
$email
->
getReplyTo
(
)
)
;
}
if
(
$email
->
getTextBody
(
)
)
{
$fields
[
'text'
]
=
$email
->
getTextBody
(
)
;
}
if
(
$email
->
getHtmlBody
(
)
)
{
$fields
[
'HTML'
]
=
$email
->
getHtmlBody
(
)
;
}
$this
->
attachmentsFormData
(
$fields
,
$email
)
;
foreach
(
$email
->
getHeaders
(
)
->
all
(
)
as
$header
)
{
if
(
$convertConf
= self::HEADER_TO_MESSAGE
[
$header
->
getName
(
)
]
?? false
)
{
$fields
[
$convertConf
]
=
$header
->
getBodyAsString
(
)
;
}
}
return
new
FormDataPart
(
$fields
)
;
}
private
function
attachmentsFormData
(
array &
$message
, Email
$email
)
: void
{