| [622] | 1 | <?php |
|---|
| 2 | // application constants |
|---|
| 3 | define('RCMAIL_VERSION', 'devel-vnext (0.1-rc1)'); |
|---|
| 4 | define('RCMAIL_CHARSET', 'UTF-8'); |
|---|
| 5 | define('JS_OBJECT_NAME', 'rcmail'); |
|---|
| 6 | |
|---|
| 7 | // define global vars |
|---|
| 8 | $OUTPUT_TYPE = 'html'; |
|---|
| 9 | $MAIN_TASKS = array( |
|---|
| 10 | 'mail', |
|---|
| 11 | 'settings', |
|---|
| 12 | 'logout' |
|---|
| 13 | ); // addressbook |
|---|
| 14 | |
|---|
| 15 | if (isset($INSTALL_PATH) === false || empty($INSTALL_PATH) === true) { |
|---|
| 16 | $INSTALL_PATH = './'; |
|---|
| 17 | } |
|---|
| 18 | else { |
|---|
| 19 | if (substr($INSTALL_PATH, -16) == '/program/include') { |
|---|
| 20 | $INSTALL_PATH = str_replace('/program/include', '', $INSTALL_PATH); |
|---|
| 21 | } |
|---|
| 22 | $INSTALL_PATH.= '/'; |
|---|
| 23 | } |
|---|
| 24 | |
|---|
| 25 | // make sure path_separator is defined |
|---|
| 26 | if (!defined('PATH_SEPARATOR')) { |
|---|
| 27 | define('PATH_SEPARATOR', (eregi('win', PHP_OS) ? ';' : ':')); |
|---|
| 28 | } |
|---|
| 29 | |
|---|
| 30 | // RC include folders MUST be included FIRST to avoid other |
|---|
| 31 | // possible not compatible libraries (i.e PEAR) to be included |
|---|
| 32 | // instead the ones provided by RC |
|---|
| 33 | $include_path = $INSTALL_PATH . PATH_SEPARATOR; |
|---|
| 34 | $include_path.= $INSTALL_PATH . 'program' . PATH_SEPARATOR; |
|---|
| 35 | $include_path.= $INSTALL_PATH . 'program/lib' . PATH_SEPARATOR; |
|---|
| [631] | 36 | $include_path.= '/usr/share/Zend-SVN/library' . PATH_SEPARATOR; |
|---|
| [622] | 37 | $include_path.= ini_get('include_path'); |
|---|
| 38 | |
|---|
| 39 | ini_set('include_path', $include_path); |
|---|
| 40 | |
|---|
| 41 | ini_set('session.name', 'sessid'); |
|---|
| 42 | ini_set('session.use_cookies', 1); |
|---|
| 43 | ini_set('session.gc_maxlifetime', 21600); |
|---|
| 44 | ini_set('session.gc_divisor', 500); |
|---|
| 45 | ini_set('error_reporting', E_ALL&~E_NOTICE); |
|---|
| 46 | |
|---|
| 47 | // increase maximum execution time for php scripts |
|---|
| 48 | // (does not work in safe mode) |
|---|
| 49 | if (!ini_get('safe_mode')) { |
|---|
| 50 | @set_time_limit(120); |
|---|
| 51 | } |
|---|
| 52 | |
|---|
| 53 | require_once 'rcube/registry.php'; |
|---|
| 54 | ?> |
|---|