Site name is used to set "From:" field in mail header (when mimemail module exists) but it is not correctly encoded if name contains i18n letters. I suggest to encode "From:" field by mime_header_encode function first.

CommentFileSizeAuthor
from_mime_header_encode.patch646 byteskndr

Comments

sutharsan’s picture

Status: Needs review » Needs work

Thank you for the patch. But this change will cause an error if simplenews is used without mimemail module.

kndr’s picture

I don't understand how is it possible? Look at function simplenews_mail_send(). Variable $form (which I have modified by patch) is used only in case if mimemail module exists (it is parameter in calling mimemail function). Well, if mimemail module doesn't exists, variable $from isn't used and therefore it's value can't have negative impact to simplenews. Where is the source of error and what kind of error have you noticed?

sutharsan’s picture

Status: Needs work » Fixed

Sorry, I looked too quickly. simplenews_mail_send() is called both for plain and html newsletters. But mime_header_encode() is a core function and not (as I thought first) a mimemail function.
Patch committed. Thanks.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.