X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;ds=sidebyside;f=functions%2Fconstants.php;h=382d3cc9e21a1d26acbd7f16e7bc78d23598c167;hb=62f7daa5b0686061e12aeeee9866c195488c0d44;hp=a762b703c8ad1dacc1537f6ef46ce6e645254ec5;hpb=fd87494d30afbfc69dafcaaaec43e287be4bc22c;p=squirrelmail.git diff --git a/functions/constants.php b/functions/constants.php index a762b703..382d3cc9 100644 --- a/functions/constants.php +++ b/functions/constants.php @@ -1,35 +1,58 @@ + +/** + * constants.php + * + * Copyright (c) 1999-2004 The SquirrelMail Project Team + * Licensed under the GNU GPL. For full terms see the file COPYING. + * + * Loads constants used by the rest of the Squirrelmail source. + * This file is include by src/login.php, src/redirect.php and + * src/load_prefs.php. + * + * @version $Id$ + * @package squirrelmail + */ + +/** Need to enable plugin functions for a hook */ +require_once(SM_PATH . 'functions/plugin.php'); /* Required for the hook */ + +/**************************************************************/ +/* Set values for constants used by Squirrelmail preferences. */ +/**************************************************************/ + +/* Define basic, general purpose preference constants. */ +define('SMPREF_NO', 0); +define('SMPREF_OFF', 0); +define('SMPREF_YES', 1); +define('SMPREF_ON', 1); +define('SMPREF_NONE', 'none'); + +/* Define constants for location based preferences. */ +define('SMPREF_LOC_TOP', 'top'); +define('SMPREF_LOC_BETWEEN', 'between'); +define('SMPREF_LOC_BOTTOM', 'bottom'); +define('SMPREF_LOC_LEFT', ''); +define('SMPREF_LOC_RIGHT', 'right'); + +/* Define preferences for folder settings. */ +define('SMPREF_UNSEEN_NONE', 1); +define('SMPREF_UNSEEN_INBOX', 2); +define('SMPREF_UNSEEN_ALL', 3); +define('SMPREF_UNSEEN_SPECIAL', 4); // Only special folders +define('SMPREF_UNSEEN_NORMAL', 5); // Only normal folders +define('SMPREF_UNSEEN_ONLY', 1); +define('SMPREF_UNSEEN_TOTAL', 2); + +/* Define constants for time/date display preferences. */ +define('SMPREF_TIME_24HR', 1); +define('SMPREF_TIME_12HR', 2); + +/* Define constants for javascript preferences. */ +define('SMPREF_JS_OFF', 0); +define('SMPREF_JS_ON', 1); +define('SMPREF_JS_AUTODETECT', 2); + +do_hook('loading_constants'); + +?> \ No newline at end of file