constants.php 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <?php
  2. /**
  3. * constants.php
  4. *
  5. * Copyright (c) 1999-2001 The SquirrelMail Development Team
  6. * Licensed under the GNU GPL. For full terms see the file COPYING.
  7. *
  8. * Loads constants used by the rest of the Squirrelmail source.
  9. * This file is include by src/login.php, src/redirect.php and
  10. * src/load_prefs.php.
  11. *
  12. * $Id$
  13. */
  14. /*****************************************************************/
  15. /*** THIS FILE NEEDS TO HAVE ITS FORMATTING FIXED!!! ***/
  16. /*** PLEASE DO SO AND REMOVE THIS COMMENT SECTION. ***/
  17. /*** + Base level indent should begin at left margin, as ***/
  18. /*** the require_once below. ***/
  19. /*** + All identation should consist of four space blocks ***/
  20. /*** + Tab characters are evil. ***/
  21. /*** + all comments should use "slash-star ... star-slash" ***/
  22. /*** style -- no pound characters, no slash-slash style ***/
  23. /*** + FLOW CONTROL STATEMENTS (if, while, etc) SHOULD ***/
  24. /*** ALWAYS USE { AND } CHARACTERS!!! ***/
  25. /*** + Please use ' instead of ", when possible. Note " ***/
  26. /*** should always be used in _( ) function calls. ***/
  27. /*** Thank you for your help making the SM code more readable. ***/
  28. /*****************************************************************/
  29. require_once('../functions/plugin.php'); // Required for the hook
  30. /**************************************************************/
  31. /* Set values for constants used by Squirrelmail preferences. */
  32. /**************************************************************/
  33. /* Define basic, general purpose preference constants. */
  34. define('SMPREF_NO', 0);
  35. define('SMPREF_OFF', 0);
  36. define('SMPREF_YES', 1);
  37. define('SMPREF_ON', 1);
  38. define('SMPREF_NONE', 'none');
  39. /* Define constants for location based preferences. */
  40. define('SMPREF_LOC_TOP', 'top');
  41. define('SMPREF_LOC_BETWEEN', 'between');
  42. define('SMPREF_LOC_BOTTOM', 'bottom');
  43. define('SMPREF_LOC_LEFT', '');
  44. define('SMPREF_LOC_RIGHT', 'right');
  45. /* Define preferences for folder settings. */
  46. define('SMPREF_UNSEEN_NONE', 1);
  47. define('SMPREF_UNSEEN_INBOX', 2);
  48. define('SMPREF_UNSEEN_ALL', 3);
  49. define('SMPREF_UNSEEN_ONLY', 1);
  50. define('SMPREF_UNSEEN_TOTAL', 2);
  51. /* Define constants for time/date display preferences. */
  52. define('SMPREF_TIME_24HR', 1);
  53. define('SMPREF_TIME_12HR', 2);
  54. /* Define constants for javascript preferences. */
  55. define('SMPREF_JS_OFF', 0);
  56. define('SMPREF_JS_ON', 1);
  57. define('SMPREF_JS_AUTODETECT', 2);
  58. do_hook('loading_constants');
  59. ?>