Page 1 of 1

updated stripQuotedText to also strip quoted mail header

Posted: Sat Oct 29, 2016 10:05 pm
by spiorf
Hi,
I'm using Hesk with mike-koch's mods-for-hesk and made a fix. He suggested to post it here too.
Ticket replies imported from email kept the previous mail header in the answer text. This change looks for the header with a regex and if it is before the "do-not-remove" line, cuts there. It may not always work, because the header depends on the mail client.

https://github.com/mike-koch/Mods-for-H ... 7f16a4599f

Re: updated stripQuotedText to also strip quoted mail header

Posted: Sun Oct 30, 2016 3:44 pm
by Klemen
Thanks for sharing.

Reliably detecting removing quoted messages is a nightmare (Google even has a rather complicated process patented) because email clients don't have standard way of doing it. Things get even worse when you start adding support for multiple languages into the mix.

While your fix works for a very specific email client (but may cause problems elsewhere), I currently do not plan on improving Hesk's quoted message functionality.