setup.php 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. /**
  3. * setup.php
  4. *
  5. * Implementation of RFC 2369 for SquirrelMail.
  6. * When viewing a message from a mailinglist complying with this RFC,
  7. * this plugin displays a menu which gives the user a choice of mailinglist
  8. * commands such as (un)subscribe, help and list archives.
  9. *
  10. * @copyright 1999-2025 The SquirrelMail Project Team
  11. * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  12. * @version $Id$
  13. * @package plugins
  14. * @subpackage listcommands
  15. */
  16. /**
  17. * Initialize the listcommands plugin
  18. */
  19. function squirrelmail_plugin_init_listcommands () {
  20. global $squirrelmail_plugin_hooks;
  21. $squirrelmail_plugin_hooks['template_construct_read_headers.tpl']['listcommands'] = 'plugin_listcommands_menu';
  22. $squirrelmail_plugin_hooks['optpage_register_block']['listcommands'] = 'plugin_listcommands_optpage_register_block';
  23. }
  24. /**
  25. * Main function added to read_body_header
  26. */
  27. function plugin_listcommands_menu() {
  28. include_once(SM_PATH . 'plugins/listcommands/functions.php');
  29. return plugin_listcommands_menu_do();
  30. }
  31. /**
  32. * Show mailing list management option section on options page
  33. */
  34. function plugin_listcommands_optpage_register_block() {
  35. include_once(SM_PATH . 'plugins/listcommands/functions.php');
  36. plugin_listcommands_optpage_register_block_do();
  37. }