From 4a1ae9a7a210495d5e568d48f6dd0e8e98c25e89 Mon Sep 17 00:00:00 2001 From: Philipp Dieter Date: Sun, 14 Nov 2021 19:02:51 +0100 Subject: [PATCH] [FEATURE] Add attachment option to mailutility --- Classes/Utility/MailUtility.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Classes/Utility/MailUtility.php b/Classes/Utility/MailUtility.php index 6f16ebe..db456d2 100644 --- a/Classes/Utility/MailUtility.php +++ b/Classes/Utility/MailUtility.php @@ -280,6 +280,13 @@ class MailUtility $bodydataText[] = $textRow; $bodydataHtml[] = $htmlRow; break; + case 'attachment': + $mail->attach(new \Swift_Attachment( + $row['data'][0], + $row['data'][1], + $row['data'][2] + )); + break; case 'attachmentBase64': $attachmentdata = explode(',', $row['data']); preg_match('/\w*:(.*);\w*/', $attachmentdata[0], $matches);