| | |
| | | } |
| | | } |
| | | |
| | | $OUTPUT->set_env('mimetypes', $mimetypes); |
| | | $OUTPUT->set_env('mimetypes', array_values($mimetypes)); |
| | | |
| | | if ($CONFIG['drafts_mbox']) |
| | | $OUTPUT->set_env('drafts_mailbox', $CONFIG['drafts_mbox']); |
| | |
| | | $OUTPUT->set_env('skip_deleted', true); |
| | | if ($CONFIG['display_next']) |
| | | $OUTPUT->set_env('display_next', true); |
| | | if ($MESSAGE->headers->others['list-post']) |
| | | if ($MESSAGE->headers->get('list-post', false)) |
| | | $OUTPUT->set_env('list_post', true); |
| | | if ($CONFIG['forward_attachment']) |
| | | $OUTPUT->set_env('forward_attachment', true); |
| | |
| | | |
| | | if (sizeof($MESSAGE->attachments)) { |
| | | foreach ($MESSAGE->attachments as $attach_prop) { |
| | | $filename = rcmail_attachment_name($attach_prop); |
| | | $filename = rcmail_attachment_name($attach_prop, true); |
| | | |
| | | if ($PRINT_MODE) { |
| | | $size = $RCMAIL->message_part_size($attach_prop); |
| | | $ol .= html::tag('li', null, Q(sprintf("%s (%s)", $filename, $size))); |
| | | } |
| | | else { |
| | | if (mb_strlen($filename) > 50) { |
| | | $filename = abbreviate_string($filename, 50); |
| | | $title = $filename; |
| | | if ($attrib['maxlength'] && mb_strlen($filename) > $attrib['maxlength']) { |
| | | $title = $filename; |
| | | $filename = abbreviate_string($filename, $attrib['maxlength']); |
| | | } |
| | | else { |
| | | $title = ''; |
| | |
| | | JS_OBJECT_NAME, |
| | | $attach_prop->mime_id, |
| | | rcmail_fix_mimetype($attach_prop->mimetype)), |
| | | 'onmouseover' => $title ? '' : 'rcube_webmail.long_subject_title_ex(this, 0)', |
| | | 'title' => Q($title), |
| | | ), |
| | | Q($filename))); |
| | |
| | | if ($email) { |
| | | // @TODO: search in all address books? |
| | | $CONTACTS = $RCMAIL->get_address_book(-1, true); |
| | | $existing = $CONTACTS->search('email', $email, true, false); |
| | | if ($existing->count) |
| | | return true; |
| | | |
| | | if (is_object($CONTACTS)) { |
| | | $existing = $CONTACTS->search('email', $email, true, false); |
| | | if ($existing->count) { |
| | | return true; |
| | | } |
| | | } |
| | | } |
| | | |
| | | return false; |