Source for file setup.php

Documentation is available at setup.php

  1. <?php
  2.  
  3. /**
  4.  * setup.php -- Sent Subfolders Setup File
  5.  *
  6.  * This is a standard SquirrelMail 1.2 API for plugins.
  7.  *
  8.  * @copyright 1999-2020 The SquirrelMail Project Team
  9.  * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  10.  * @version $Id: setup.php 14845 2020-01-07 08:09:34Z pdontthink $
  11.  * @package plugins
  12.  * @subpackage sent_subfolders
  13.  */
  14.  
  15. /**
  16.  * Adds plugin to SquirrelMail's hooks
  17.  */
  18.     /* Standard initialization API. */
  19.     global $squirrelmail_plugin_hooks;
  20.  
  21.     /* The hooks to make the sent subfolders display correctly. */
  22.     $squirrelmail_plugin_hooks['check_handleAsSent_result']['sent_subfolders']
  23.         = 'sent_subfolders_check_handleAsSent';
  24.  
  25.     /* The hooks to automatically update sent subfolders. */
  26. // hook isn't in 1.5.x; isn't absolutely necessary to run on the folder list anyway
  27. //    $squirrelmail_plugin_hooks['left_main_before']['sent_subfolders']
  28. //        = 'sent_subfolders_update_sentfolder';
  29.     $squirrelmail_plugin_hooks['compose_send']['sent_subfolders']
  30.         = 'sent_subfolders_update_sentfolder';
  31.  
  32.     /* The hooks to handle sent subfolders options. */
  33.     $squirrelmail_plugin_hooks['optpage_loadhook_folder']['sent_subfolders']
  34.         = 'sent_subfolders_optpage_loadhook_folders';
  35.  
  36.     /* mark base sent folder as special mailbox */
  37.     $squirrelmail_plugin_hooks['special_mailbox']['sent_subfolders']
  38.         = 'sent_subfolders_special_mailbox';
  39. }
  40.  
  41. function sent_subfolders_check_handleAsSent($mailbox{
  42.     include_once(SM_PATH 'plugins/sent_subfolders/functions.php');
  43. }
  44.  
  45. /**
  46.  * Adds sent_subfolders options in folder preferences
  47.  */
  48.     include_once(SM_PATH 'plugins/sent_subfolders/functions.php');
  49. }
  50.  
  51. /**
  52.  * Update sent_subfolders settings
  53.  *
  54.  * function updates default sent folder value and
  55.  * creates required imap folders
  56.  */
  57.     include_once(SM_PATH 'plugins/sent_subfolders/functions.php');
  58. }
  59.  
  60. /**
  61.  * detects if mailbox is part of sent_subfolders
  62.  *
  63.  * @param string $mb imap folder name
  64.  * @return boolean 1 - is part of sent_subfolders, 0 - is not part of sent_subfolders
  65.  */
  66.     include_once(SM_PATH 'plugins/sent_subfolders/functions.php');
  67. }

Documentation generated on Mon, 13 Jan 2020 04:23:32 +0100 by phpDocumentor 1.4.3