Item8294: A couple of improvements: Utf8 encoding and attachments list after an entry

pencil
Priority: Enhancement
Current State: Closed
Released In: n/a
Target Release:
Applies To: Extension
Component: MailInContrib
Branches:
Reported By: Foswiki:Main.IgnacioAliendeGarcia
Waiting For:
Last Change By: CrawfordCurrie
Here I send a couple of improvements we had to this extension: - The first is to repair the text entry when the email is encoded in latin so we encode in utf8 before doing the change. - The second is to put a list of links for the attachments included in the email right after the entry text (by now we have the wiki list of attachment at the bottom of the page but in this form is more easy to find one file by context)

-- IgnacioAliendeGarcia - 30 Sep 2009

I suspect that a better way to get a list of links to the attachments below each email would be to update the %ATTACHMENT% template. In System.MailInContribTemplate, I would change this:
%TMPL:DEF{MAILIN:normal:ATTACHMENT}%      * %A_FILE%
to this:
%TMPL:DEF{MAILIN:normal:ATTACHMENT}%      * [[%ATTACHURL%/%A_FILE%][%A_FILE]]

-- MichaelTempest - 14 Feb 2010

Encoding to UTF-8 is appropriate when the site encoding is UTF-8. Whatever encoding the mail comes in, it should be converted to the site encoding, so the patch is correct in principle, but in practice will end up breaking most sites.

On the attachment links, Michael's suggestion is the right way to go.

-- CrawfordCurrie - 15 Feb 2010

I changed the default template in MailInContrib:4a417cbb59cd.

-- MichaelTempest - 21 Feb 2010

ItemTemplate edit

Summary A couple of improvements: Utf8 encoding and attachments list after an entry
ReportedBy Foswiki:Main.IgnacioAliendeGarcia
Codebase
SVN Range
AppliesTo Extension
Component MailInContrib
Priority Enhancement
CurrentState Closed
WaitingFor
Checkins MailInContrib:4a417cbb59cd distro:b04388aa0629
ReleasedIn n/a
CheckinsOnBranches
trunkCheckins
masterCheckins
ItemBranchCheckins
Release01x01Checkins
I Attachment Action Size Date Who Comment
mailincontrib.patchpatch mailincontrib.patch manage 2 K 30 Sep 2009 - 15:37 IgnacioAliendeGarcia Patch including utf8 encoding from latin and list attachment after the entry text
Topic revision: r8 - 19 May 2015, CrawfordCurrie
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy