[dev] Show attachment icon on messages without attachments
Jan Schneider
jan at horde.org
Tue Apr 6 20:46:38 UTC 2010
Zitat von Michael M Slusarz <slusarz at horde.org>:
> Quoting Gonçalo Queirós <mail at goncaloqueiros.net>:
>
>> Hi there list.
>> Since Horde now can render HTML inline, i saw a strange behavior on IMP.
>> If the html is being rendered inline, when the user opens an email, he
>> will not see the html parts on the attachment "zone". So if the email
>> only contains html parts, there will be no attachment to download. The
>> strange behavior is when you view the message on the Inbox list (e.g.)
>> it will have the attachment icon.
>> Shouldn't messages that contain only parts that can be rendered inline
>> not have the attachment icon?
>
> This is by design. The attachment icon is meant to be displayed
> using as little system resources as possible.
>
> It is a terrible idea to parse the contents of every message to
> determine whether it contains attachments. In many cases, this can
> only be determined via a detailed analysis of the structure and/or
> downloading contents of a message part from the server.
>
> The attachment icon is meant to be a compromise. It is not meant to
> describe whether attachments, in the sense that a file can
> potentially be downloaded from the message, are present. It instead
> describes whether attachments exist from a MIME point of view -
> namely, any message containing more than one part (i.e. a multipart
> message) contains attachments.
>
> I have struggled off and on for awhile with myself whether to remove
> this flag entirely. After thinking about it a bit more, I am
> seriously considering removing it.
How about another compromise and showing it only for multipart
messages that are not multipart/alternative in the base mime part?
Jan.
--
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
More information about the dev
mailing list