magepal / magento2-gmail-smtp-app

Configure Magento 2 to send email using Google App, Gmail, Amazon Simple Email Service (SES), Microsoft Office365 and many other SMTP (Simple Mail Transfer Protocol) servers
https://www.magepal.com
319 stars 147 forks source link

SUBJ_ILLEGAL_CHARS Subject: has too many raw illegal characters #127

Closed mvenghaus closed 5 years ago

mvenghaus commented 5 years ago

Hello,

we're sending our emails in german. And it seems that the subject is not send as utf8!?

Would be nice if you can help :)

Regards Marcus

srenon commented 5 years ago

could you provide more information... like what version of Magento and this module are you using

mvenghaus commented 5 years ago

Magento 2.3 and 1.2 from your module

mvenghaus commented 5 years ago

I've found a workaround/fix for me.

https://github.com/magepal/magento2-gmail-smtp-app/blob/master/Model/TwoDotThree/Smtp.php#L74

Here the message is created. The default is ASCII so the encoding of the header is also set to ASCII and it's not changed after that. When I add the following line everything works. Don't know if that's the right place for the fix!?

$message = Message::fromString($message->getRawMessage());
$message->getHeaders()->setEncoding('utf-8');

Regards Marcus

srenon commented 5 years ago

@mvenghaus ... will be fixed in next update

Artem-Schander commented 5 years ago

Besides that Issue, there is a similar one:

2019-04-09-093037_967x350_scrot

mvenghaus commented 5 years ago

That's not an extension issue .. it should be handled by magento .. but when you make all other things correct you don't have to care about this one,