summaryrefslogtreecommitdiff
path: root/roundcubemail/program/steps/mail/show.inc
diff options
context:
space:
mode:
authoralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2012-04-13 08:52:02 +0000
committeralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2012-04-13 08:52:02 +0000
commitd61fd77d83926d892645a15e00c3443d2a8a6368 (patch)
tree83ede4b27294a42a45ee988751f51182994e0de7 /roundcubemail/program/steps/mail/show.inc
parent8a3df3f032059464ebaab2dde26ab0d24b186572 (diff)
- Merge devel-framework branch, resolved conflicts
git-svn-id: https://svn.roundcube.net/trunk@6073 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/steps/mail/show.inc')
-rw-r--r--roundcubemail/program/steps/mail/show.inc24
1 files changed, 14 insertions, 10 deletions
diff --git a/roundcubemail/program/steps/mail/show.inc b/roundcubemail/program/steps/mail/show.inc
index c6c6d9636..076098a56 100644
--- a/roundcubemail/program/steps/mail/show.inc
+++ b/roundcubemail/program/steps/mail/show.inc
@@ -126,20 +126,24 @@ function rcmail_message_attachments($attrib)
if (sizeof($MESSAGE->attachments)) {
foreach ($MESSAGE->attachments as $attach_prop) {
- if ($PRINT_MODE) {
- $ol .= html::tag('li', null, sprintf("%s (%s)", Q($attach_prop->filename), Q(show_bytes($attach_prop->size))));
+ $filename = $attach_prop->filename;
+ if (empty($filename) && $attach_prop->mimetype == 'text/html') {
+ $filename = rcube_label('htmlmessage');
}
- else {
- if (mb_strlen($attach_prop->filename) > 50) {
- $filename = abbreviate_string($attach_prop->filename, 50);
- $title = $attach_prop->filename;
+
+ if ($PRINT_MODE) {
+ $ol .= html::tag('li', null, sprintf("%s (%s)", Q($filename), Q(show_bytes($attach_prop->size))));
}
else {
- $filename = $attach_prop->filename;
- $title = '';
- }
+ if (mb_strlen($filename) > 50) {
+ $filename = abbreviate_string($filename, 50);
+ $title = $filename;
+ }
+ else {
+ $title = '';
+ }
- $ol .= html::tag('li', rcmail_filetype2classname($attach_prop->mimetype, $attach_prop->filename),
+ $ol .= html::tag('li', rcmail_filetype2classname($attach_prop->mimetype, $filename),
html::a(array(
'href' => $MESSAGE->get_part_url($attach_prop->mime_id, false),
'onclick' => sprintf(