Problem with encoding in email subject - 6.3 or 6.4 | Adobe Higher Education
Skip to main content
Level 2
August 26, 2019

Problem with encoding in email subject - 6.3 or 6.4

  • August 26, 2019
  • 3 の返信
  • 8217 ビュー

Hi Everyone,

I have a problem with subject encoding. My email subject contains these chinese characters - 意向客户-参展预订-CN官网渠道 (emailSubject is the property name in the JCR to store this value) but when a User receives an email, these characters are shown like this - 意向客户-参展预订-CNå®˜ç½‘æ¸ é“

I have checked in the Publisher Logs interacting with SMTP Server and I'm getting this in the logs:

Subject: =?UTF-8?B?w6bChMKPw6XCkMKRw6XCrsKiw6bCiMK3LcOlwo/CgsOlwrHClcOp?=

=?UTF-8?B?wqLChMOowq7Coi1DTsOlwq7CmMOnwr3CkcOmwrjCoMOpwoHCkw==?=

MIME-Version: 1.0

Content-Type: text/plain; charset=UTF-8

Content-Transfer-Encoding: quoted-printable

Template is defined as:

From: noreply@testmail.co.uk

Subject: ${emailSubject}

Author name: ${authorName}

${formData}

All other custom fields (like firstName, lastName etc) looks fine and enoding/decoding also looks Ok for these fields:

title: =E5=A4=AB=E4=BA=BA

salutation: =E5=8D=9A=E5=A3=AB=E6=95=99=E6=8E=88

firstname: =E9=9C=80=E8=A6=81=E5=A1=AB=E5=86=99=E7=A7=B0=E8=B0=93

surname: =E9=9C=80=E8=A6=81=E5=A1=AB=E5=86=99=E7=A7=B0=E8=B0=93

Seems to be encoding issue for the Subject Field.

Has anyone encountered this issue while using EmailService.sendEmail(var1, var2, var3)?

このトピックへの返信は締め切られました。

3 の返信

Gaurav-Behl
Level 10
August 27, 2019

Check if this helps In Mail question mark is coming in place of special characters

Did you try to reproduce this issue with an updated version of acs commons?

aemuser2021作成者
Level 2
August 27, 2019

Yes, I am using ACS Commons version 3.19.0.

Also, I tried to put the hard-coded Chinese string in the mail (abc.txt) directly and this is still not working.

Level 3
February 25, 2020

I am also facing the same issue while using day cq mail service. Subject line with French characters are getting encoded and displayed. Can you please help

 

@71132 @14414417 @smacdonald2008