E
E
ErickSkrauch2014-09-26 22:20:24
PHP
ErickSkrauch, 2014-09-26 22:20:24

What's the problem with encoding in SwiftMailer?

I am writing a project on the Phalcon framework and on the Internet I found a ready-made service for integration with the SwiftMailer mailer. Everything is very good, convenient, but here is the outgoing encoding... Here is an example of a sent message:

Sample letter
To: [email protected]
Subject: =?utf-8?Q?=D0=9C=D0=BE=D0=B4=D0=B5=D1=80=D0=B0=D1=82=D0=BE?=
 =?utf-8?Q?=D1=80_=D0=B8=D0=B7=D0=BC=D0=B5=D0=BD=D0=B8=D0=BB_=D1=81=D1=82?=
 =?utf-8?Q?=D0=B0=D1=82=D1=83=D1=81_=D0=BC=D0=BE=D0=B4=D0=B0?=
X-PHP-Originating-Script: 0:SimpleMailInvoker.php
Message-ID: <[email protected]>
Date: Fri, 26 Sep 2014 21:29:20 +0400
From: "Ely.by" <[email protected]>
MIME-Version: 1.0
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

<p>=D0=97=D0=B4=D1=80=D0=B0=D0=B2=D1=81=D1=82=D0=B2=D1=83=D0=B9=D1=82=D0=
=B5, ErickSkrauch.</p>
<p></p>
<p>=D0=9C=D0=BE=D0=B4 "Test mod 2" =D0=B1=D1=8B=D0=BB =D0=BF=D1=80=D0=BE=
=D0=B2=D0=B5=D1=80=D0=B5=D0=BD =D0=BC=D0=BE=D0=B4=D0=B5=D1=80=D0=B0=D1=
=82=D0=BE=D1=80=D0=BE=D0=BC <a href=3D"http://ely.by/u15" title=3D"=D0=
=9F=D1=80=D0=BE=D1=84=D0=B8=D0=BB=D1=8C =D0=BC=D0=BE=D0=B4=D0=B5=D1=80=
=D0=B0=D1=82=D0=BE=D1=80=D0=B0">ErickSkrauch</a>. =D0=92 =D1=80=D0=B5=D0=
=B7=D1=83=D0=BB=D1=8C=D1=82=D0=B0=D1=82=D0=B5 =D0=BF=D1=80=D0=BE=D0=B2=
=D0=B5=D1=80=D0=BA=D0=B8 =D0=BC=D0=BE=D0=B4 .</p>
<p>=D0=9D=D0=B5=D0=BE=D0=B1=D1=85=D0=BE=D0=B4=D0=B8=D0=BC=D0=BE =D0=B4=
=D0=BE=D0=BF=D0=BE=D0=BB=D0=BD=D0=B8=D1=82=D1=8C:</p>
<blockquote><ul>
<li>=D0=9C=D0=BE=D0=B4 =D0=B3=D0=BE=D0=B2=D0=BD=D0=BE!</=
li>
</ul></blockquote>
<br />
<p><b>=D0=9F=D0=B5=D1=80=D0=B5=D0=B9=D1=82=D0=B8 =D0=BD=D0=B0 =D1=81=D1=
=82=D1=80=D0=B0=D0=BD=D0=B8=D1=86=D1=83 =D1=80=D0=B5=D0=B4=D0=B0=D0=BA=
=D1=82=D0=B8=D1=80=D0=BE=D0=B2=D0=B0=D0=BD=D0=B8=D1=8F =D0=BC=D0=BE=D0=
=B4=D0=B0:</b> <a href=3D"/mods/test_mod_2/edit">/mods/test_mod_2/edit</a><=
/p>
<br /><br />
<sup>
    <b><a href=3D"http://ely.by" title=3D"=D0=9F=D0=B5=D1=80=D0=B5=D0=B9=
=D1=82=D0=B8 =D0=BD=D0=B0 =D1=81=D0=B0=D0=B9=D1=82">Ely.by</a> =E2=80=94 =
=D1=81=D0=B8=D1=81=D1=82=D0=B5=D0=BC=D0=B0 =D1=81=D0=BA=D0=B8=D0=BD=D0=
=BE=D0=B2 =D0=B8 =D0=BA=D0=B0=D1=82=D0=B0=D0=BB=D0=BE=D0=B3 =D0=BC=D0=BE=
=D0=B4=D0=BE=D0=B2 =D0=B4=D0=BB=D1=8F Minecraft.
</sup>

The whole project is in UTF-8, the service is the same, SwiftMailer too. On the site for selecting encodings, they said that it was koi-7 or iso8859-5, but I didn’t order one, and there’s nothing like that in the source code of the service either.
How can this be fixed?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
KorsaR-ZN, 2014-09-28
@KorsaR-ZN

How exactly do you send a letter? show a code example, maybe view in the wrong encoding?
There is a similar component , the API is similar to the component from the question, but this one is with event support, the encoding can be changed through the charset method .
If you use the incubator for Phalcon, then in the latest version this component is already built into it, if not, then you can install it separately via composer

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question