/functions/attachment_common.php

Description

attachment_common.php

This file provides the handling of often-used attachment types.

  • version: $Id: attachment_common.php 14845 2020-01-07 08:09:34Z pdontthink $
  • copyright: 1999-2020 The SquirrelMail Project Team
  • todo: document attachment $type hook arguments
  • filesource: Source Code for this file
  • license: GNU Public License
Variables
array $FileExtensionToMimeType (line 25)

Mapping of file extensions to mime types

Used for application/octet-stream mime type detection. Supported extensions: bmp, gif, htm, html, jpg, jpeg, php, png, rtf, txt, patch (since 1.4.2), vcf

Functions
attachment_common_link_html (line 191)

Adds href and text keys to attachment_common array for html attachments

  • since: 1.2.0
void attachment_common_link_html ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
attachment_common_link_image (line 213)

Adds href and text keys to attachment_common array for image attachments

  • since: 1.2.0
void attachment_common_link_image ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
attachment_common_link_message (line 175)

Adds href and text keys to attachment_common array for rfc822 attachments

  • since: 1.2.6
void attachment_common_link_message ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
attachment_common_link_text (line 136)

Adds href and text keys to attachment_common array for text attachments

  • since: 1.2.0
void attachment_common_link_text ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
attachment_common_link_vcard (line 241)

Adds href and text keys to attachment_common array for vcard attachments

  • since: 1.2.0
void attachment_common_link_vcard ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
attachment_common_octet_stream (line 261)

Processes octet-stream attachments.

Calls attachment_common-load_mime_types and attachment $type hooks.

  • since: 1.2.0
void attachment_common_octet_stream ( &$Args, array $Args)
  • array $Args: attachment $type hook arguments
  • &$Args
register_attachment_common (line 118)

Function which optimizes readability of the above code, and also ensures that the attachment_common code is exectuted before any plugin, so that the latter may override the default processing.

Registers 'attachment $type' hooks.

  • since: 1.2.0
void register_attachment_common (string $type, string $func)
  • string $type: Attachment type
  • string $func: Suffix of attachment_common_* function, which handles $type attachments.

Documentation generated on Mon, 13 Jan 2020 04:22:01 +0100 by phpDocumentor 1.4.3