You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

setup.php 2.0KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <?php
  2. // vim:ts=4:sw=4:et
  3. include_once(SM_PATH . 'functions/i18n.php');
  4. function squirrelmail_plugin_init_postfixadmin() {
  5. include(dirname(__FILE__) . '/config.php');
  6. global $squirrelmail_plugin_hooks;
  7. $squirrelmail_plugin_hooks['optpage_register_block']['postfixadmin'] = 'postfixadmin_optpage_register_block';
  8. }
  9. function postfixadmin_version() {
  10. return '2.3.0';
  11. }
  12. function postfixadmin_optpage_register_block() {
  13. // Gets added to the user's OPTIONS page.
  14. global $optpage_blocks;
  15. global $AllowVacation;
  16. global $AllowChangePass;
  17. // if ( !soupNazi() ) {
  18. bindtextdomain('postfixadmin', SM_PATH . 'plugins/postfixadmin/locale');
  19. textdomain('postfixadmin');
  20. $optpage_blocks[] = array(
  21. 'name' => _("Forwarding"),
  22. 'url' => '../plugins/postfixadmin/postfixadmin_forward.php',
  23. 'desc' => _("Here you can create and edit E-Mail forwards."),
  24. 'js' => false
  25. );
  26. bindtextdomain('squirrelmail', SM_PATH . 'locale');
  27. textdomain('squirrelmail');
  28. bindtextdomain('postfixadmin', SM_PATH . 'plugins/postfixadmin/locale');
  29. textdomain('postfixadmin');
  30. if ($AllowVacation) {
  31. $optpage_blocks[] = array(
  32. 'name' => _("Auto Response"),
  33. 'url' => '../plugins/postfixadmin/postfixadmin_vacation.php',
  34. 'desc' => _("Set an OUT OF OFFICE message or auto responder for your mail."),
  35. 'js' => false
  36. );
  37. bindtextdomain('squirrelmail', SM_PATH . 'locale');
  38. textdomain('squirrelmail');
  39. }
  40. bindtextdomain('postfixadmin', SM_PATH . 'plugins/postfixadmin/locale');
  41. textdomain('postfixadmin');
  42. if ($AllowChangePass) {
  43. $optpage_blocks[] = array(
  44. 'name' => _("Change Password"),
  45. 'url' => '../plugins/postfixadmin/postfixadmin_changepass.php',
  46. 'desc' => _("Change your mailbox password."),
  47. 'js' => false
  48. );
  49. bindtextdomain('squirrelmail', SM_PATH . 'locale');
  50. textdomain('squirrelmail');
  51. }
  52. }