Using latest dev version of simplenews and mimemail, the subject is blank in emails sent.
When I turn on log, watchdog seems to show that the subject is passed as "message type" and not as subject. Look :
Outgoing email. Message type: test
Subject:
Recipient: philippe.jadin@**** Sent via Mime Mail
Investigating
Comments
Comment #1
simon georges commentedMimemail support in D7 is pretty much broken for now (see #1090016: Newsletter sent when Mail system set to Standard / not when set to Mime mail, #1048254: Support Mime Mail on Drupal 7, #1106730: Several Notices, Malformed Emails). Don't hesitate to provide some debug, I'll work on that next week.
Comment #2
philippejadin commentedSame problem without mimemail (well mimemail installed, but mail sent as plain text). I cannot explain more. It seems the subject is not passed to drupal_mail, is it possible?
How can I debug this ?
Comment #3
philippejadin commentedOk, after some more testings :
First time a node is saved than sent using the test feature, the mail has a subject. If I edit the node and save it back, the mail won't have a subject anymore.
It seems the whole array is not right, it is shifted one element.
Sorry, I'm not a "real" developer :-)
Comment #4
simon georges commentedThe subject comes from the Newsletter defintion (when you edit the newsletter category, you can choose the title (using tokens)). What do you have in this field ?
Comment #5
philippejadin commentedI tried to remove the first part, so the token is not enclosed in two [[ ]], also tried to put a fixed string like "test", but it still doesn't work.
I suspect an array containing all the email headers and fields is shifted somewhere.
Comment #6
simon georges commentedIt's strange, I never had that bug.
Could you eventually disable mimemail, to see if there is a conflict in the current version ?
Comment #7
simon georges commentedComment #8
facine commentedThis happens if the subject field contains for example: ". ", "¿", etc ...
Comment #9
simon georges commentedIs it the same with Drupal standard mails ? For example if you add such characters in "New password" e-mail subject ?
Comment #10
facine commentedNew password subject works fine
Comment #11
simon georges commentedOk, thanks for your help in debugging, I will check that !
Comment #12
miro_dietikerSmells like a mimemail issue to me... Mimemail needs some love to improve all encoding (probably decoding) cases.
Sounds like the coding somehow failed...
Someone please add debug statements in code (devel, dpm, ...) and provide feedback. We might even move this issue over to Mimemail then.
Comment #13
philippejadin commentedI can confirm that html sending works (at least when sending test email) with latest simplenews and mimemail dev and drupal 7.2.
However, the subject of the email disappears in this situation :
- create a simplenews node with title "test"
- send a test email
-> email received with the correct title
- edit again the node, save it
- send a test email
-> email subject is blank.
This bug appears with and without token in the configured newsletter title.
Comment #14
gratefulsk commentedI don't believe this is a MIME MAIL issue. I am using HTML Mail and I am receiving the exact same problem.
It would be great if this bug got resolved.
Comment #15
gratefulsk commentedFound a workaround!
OK, so after days of testing every possibility imagined, I believe revisions is a culprit for causing this issue. I decided to edit the newsletter content type setting to not create a new revision. I then created my newsletter and edited it over 5 times with the subject successfully being sent on the test emails as well as the final send.
So, I am not sure why not creating a revision bypasses this issue, but I am just glad that my client can now edit his newsletters with no problems with the subject.
I am using:
Simplenews 7.x-1.x-dev
HTML Mail 7.x-2.60
Comment #16
simon georges commentedRevisions are not supported at all (see #1114090: Remove broken revision handling).
Anyway, thanks for your feedback, maybe we could find a way to at least have the title working.
Comment #17
philippejadin commentedI can confirm that the title is kept if revision are disabled / not used for the simplenews content type.
In Structure -> Content Type -> Simplenews -> Edit
You have to uncheck "Create a new revision"
And I guess you cannot create a new revision when saving the simplenews node you are working on.
(Simplenews Drupal 7 seems to be usable now, I will report on a 10.000+ subscribers mailing soon)
Comment #18
berdirClosing this issue as a duplicate of #1114090: Remove broken revision handling then as multiple reports have shown that this issue is because of broken revision handling.
Comment #19
ryank76 commentedI have revisions unchecked for both content types that I am using as a newsletter (Simplenews newsletter and Article) and am still experiencing the issue. So I don't believe it's a duplicate of that issue and I am unable to find a cause or workaround.
EDIT: I switched from 7.x-1.0-alpha1 to 7.x-1.x-dev and that has fixed the issue.
Comment #20
simon georges commentedLet's let it closed if it's fixed in -dev ;-)