Vote #74728
完了Scraped emails include CSS from HTML emails
0%
説明
I'm not sure how many others are encountering this behavior, but when replying to an email notification (and making sure to remove all text from the body) the CSS for HTML emails is included as if it were written by the user. In this particular case I responded to a notification using the default mail client from iOS 7.
Example reply:
Sure, that will work. body { font-family: Verdana, sans-serif; font-size: 0.8em; color:#484848; } h1, h2, h3 { font-family: "Trebuchet MS", Verdana, sans-serif; margin: 0px; } h1 { font-size: 1.2em; } h2, h3 { font-size: 1.1em; } a, a:link, a:visited { color: #2A5685;} a:hover, a:active { color: #c61a1a; } a.wiki-anchor { display: none; } fieldset.attachments {border-width: 1px 0 0 0;} hr { width: 100%; height: 1px; background: #ccc; border: 0; } span.footer { font-size: 0.8em; font-style: italic; }
Our environment:
Redmine version 2.4.1.stable.12325 Ruby version 1.8.7-p352 (2011-06-30) [i686-linux] Rails version 3.2.15 Environment production Database adapter MySQL
journals
Is there any additional information that I can provide? Any tips/config changes that I can try?
Thanks.
--------------------------------------------------------------------------------
I cannot reproduce with Redmine 2.5.1/iOS 7.1.1. Does this problem still occur?
--------------------------------------------------------------------------------
Hi,
Thanks for the reply. Yes, it occurs every time I send an email from an iOS device. I have not _yet_ tested with the newly released Redmine 2.5.2, but I will do so and post back with my results.
--------------------------------------------------------------------------------
Deoren Moor wrote:
> Yes, it occurs every time I send an email from an iOS device.
To be clear, my OP had the key ingredient:
> I responded to a notification using the default mail client from iOS 7.
I did not see the behavior when sending in the initial report, but when replying to an email that is when I noticed it. It's also worth noting that we have our Redmine installation configured to send HTML emails and not plaintext emails.
It probably doesn't make a difference, but I sent the test email and test reply from an iOS 7.1.2 device.
--------------------------------------------------------------------------------
No problem with iOS 7.1.2 and notification from www.redmine.org. What happens when you reply to the notification from www.redmine.org?
!{width: 320px;}reply_to_the_notification_15176.png!
--------------------------------------------------------------------------------
I just replied, but I noticed that the address I was replying to is 'noreply@redmine.org', so I suspect it will not end up here.
Is there any additional information I can supply about our setup?
--------------------------------------------------------------------------------
Sounds like someone else is having the problem too (maybe they just posted to the wrong ticket): #10929#note-4
--------------------------------------------------------------------------------
Digging back through our Redmine system I found that the earliest example of this happening is June 24, 2013. We would have been running whatever Redmine version was current at the time. If I'm not mistaken, that would be version version:2.3.1.
--------------------------------------------------------------------------------
Note: this is still a problem as of Redmine 3.0.2. We see it often for current versions of Mac OS X and iOS. I'm still using iOS 7 on a work device, and I see the behavior with it as well.
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Still a problem as of Redmine 3.0.3 + back-ported changes in r14313.
--------------------------------------------------------------------------------
Works fine for me when replying from iOS 8.3 with current trunk (including r14313), here is what I get in Redmine:
!reply_from_ios.png!
Can you send a test reply to my email address (jp_lang@yahoo.fr) so I can try to reproduce?
--------------------------------------------------------------------------------
My reply from iOS contains a plain text part and a html part so Redmine chooses the plain text part, with the result above.
If I manually remove the plain text part before submitting the email to Redmine, here is was I get:
!html_reply_from_ios.png!
--------------------------------------------------------------------------------
Jean-Philippe Lang wrote:
> Works fine for me when replying from iOS 8.3 with current trunk (including r14313), here is what I get in Redmine:
>
> ...
>
> Can you send a test reply to my email address (jp_lang@yahoo.fr) so I can try to reproduce?
Thanks for the reply and for testing.
I was a bit confused when I saw your example, so I took a closer look at Apple Mail on my iPhone 4 w/iOS 7.1.2 and found that the *@Increase Quote Level@* was set to *Off*. I tried with it both *Off* and *On* and got the same results. This is with me doing nothing more than adding my reply at the top and hitting send.
I'm going to forward the emails as an attachment (from Outlook) to the personal email address you've listed. If you'd rather have them in a different format please let me know and I'll provide them in whichever format you wish. Thanks again for looking into this.
--------------------------------------------------------------------------------
Just sent two samples, one with *@Increase Quote Level@* On and another with it set to Off. Both appear to give the same results:
{{thumbnail(redmine_3.0.3+r14313_replies_from_iPhone4_iOS_7.1.2.png, size=500, title=Click to enlarge)}}
In the past the CSS wasn't collapsed and looked more like what was shown in the OP.
--------------------------------------------------------------------------------
This should be fixed by r14315, style tags inside html body were not removed. Please reopen if you still experience the problem after this.
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Good day!
I am from task http://www.redmine.org/issues/20311
I apply r14315 (http://www.redmine.org/projects/redmine/repository/revisions/14315).
But now i receive styles in my tasks(
P {margin-top:0;margin-bottom:0;}
test
--------------------------------------------------------------------------------
Dmitriy Ermakov wrote:
> I apply r14315 (http://www.redmine.org/projects/redmine/repository/revisions/14315).
> But now i receive styles in my tasks(
>
> P {margin-top:0;margin-bottom:0;}
>
> test
You need to apply r14313 at first.
--------------------------------------------------------------------------------
related_issues
relates,Closed,19740,"Truncate emails after one of these lines" setting is not working
relates,Closed,20311,Task from Email - Styles in task text