I have searched in this forum but could not find an answer to this question. Hopefully somebody recognizes it and can help me out!
In our website we have build an email newsletter function. In fact, we build two: one aimed at members, one aimed at external subscribers. Our problem is that when we want to send an e-mail through our newsletter functionality that special characters (like single and double quotes) and diacrites (like ë and è, of which the Dutch language has quite a lot) are displayed incorrectly. A double quote, for instance, becomes " which does not make the e-mail well-readable.
In our newsletter function we simply build up the text from custom typed text or published news items, and prepare it for sending using this command:
Then, we use the cms:send_mail tag (stating html='1') to finally dispatch the message:
When we want to send an e-mail that includes the text "Corona-proof", it displays like this:
Does anyone happen to know an answer for this?
Since send_mail uses PHPMailer, it may have something to do with a setting somewhere?
In our website we have build an email newsletter function. In fact, we build two: one aimed at members, one aimed at external subscribers. Our problem is that when we want to send an e-mail through our newsletter functionality that special characters (like single and double quotes) and diacrites (like ë and è, of which the Dutch language has quite a lot) are displayed incorrectly. A double quote, for instance, becomes " which does not make the e-mail well-readable.
In our newsletter function we simply build up the text from custom typed text or published news items, and prepare it for sending using this command:
- Code: Select all
$text= nl2br(htmlspecialchars(utf8_encode($text),ENT_QUOTES | ENT_COMPAT,'UTF-8'));
Then, we use the cms:send_mail tag (stating html='1') to finally dispatch the message:
- Code: Select all
<cms:send_mail to="<cms:show item />" from='newsletter@email.com' subject="<cms:show messagesubject />" html='1' >
<cms:show messagehtml />
</cms:send_mail>
When we want to send an e-mail that includes the text "Corona-proof", it displays like this:
- Code: Select all
"Corona-proof"
Does anyone happen to know an answer for this?
Since send_mail uses PHPMailer, it may have something to do with a setting somewhere?