Andrey Andreev | e734b38 | 2012-03-26 13:42:36 +0300 | [diff] [blame] | 1 | <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); |
Derek Jones | f4a4bd8 | 2011-10-20 12:18:42 -0500 | [diff] [blame] | 2 | /** |
| 3 | * CodeIgniter |
| 4 | * |
Phil Sturgeon | 07c1ac8 | 2012-03-09 17:03:37 +0000 | [diff] [blame] | 5 | * An open source application development framework for PHP 5.2.4 or newer |
Derek Jones | f4a4bd8 | 2011-10-20 12:18:42 -0500 | [diff] [blame] | 6 | * |
| 7 | * NOTICE OF LICENSE |
Andrey Andreev | e734b38 | 2012-03-26 13:42:36 +0300 | [diff] [blame] | 8 | * |
Derek Jones | f4a4bd8 | 2011-10-20 12:18:42 -0500 | [diff] [blame] | 9 | * Licensed under the Academic Free License version 3.0 |
Andrey Andreev | e734b38 | 2012-03-26 13:42:36 +0300 | [diff] [blame] | 10 | * |
Derek Jones | 61df906 | 2011-10-21 09:55:40 -0500 | [diff] [blame] | 11 | * This source file is subject to the Academic Free License (AFL 3.0) that is |
Derek Jones | f4a4bd8 | 2011-10-20 12:18:42 -0500 | [diff] [blame] | 12 | * bundled with this package in the files license_afl.txt / license_afl.rst. |
| 13 | * It is also available through the world wide web at this URL: |
| 14 | * http://opensource.org/licenses/AFL-3.0 |
| 15 | * If you did not receive a copy of the license and are unable to obtain it |
| 16 | * through the world wide web, please send an email to |
| 17 | * licensing@ellislab.com so we can send you a copy immediately. |
| 18 | * |
| 19 | * @package CodeIgniter |
| 20 | * @author EllisLab Dev Team |
Andrey Andreev | 80500af | 2013-01-01 08:16:53 +0200 | [diff] [blame] | 21 | * @copyright Copyright (c) 2008 - 2013, EllisLab, Inc. (http://ellislab.com/) |
Derek Jones | f4a4bd8 | 2011-10-20 12:18:42 -0500 | [diff] [blame] | 22 | * @license http://opensource.org/licenses/AFL-3.0 Academic Free License (AFL 3.0) |
| 23 | * @link http://codeigniter.com |
| 24 | * @since Version 1.0 |
| 25 | * @filesource |
| 26 | */ |
Derek Allard | 2067d1a | 2008-11-13 22:59:24 +0000 | [diff] [blame] | 27 | |
| 28 | /* |
| 29 | |-------------------------------------------------------------------------- |
| 30 | | File and Directory Modes |
| 31 | |-------------------------------------------------------------------------- |
| 32 | | |
| 33 | | These prefs are used when checking and setting modes when working |
Derek Jones | 37f4b9c | 2011-07-01 17:56:50 -0500 | [diff] [blame] | 34 | | with the file system. The defaults are fine on servers with proper |
Derek Allard | 2067d1a | 2008-11-13 22:59:24 +0000 | [diff] [blame] | 35 | | security, but you may wish (or even need) to change the values in |
| 36 | | certain environments (Apache running a separate process for each |
Derek Jones | 37f4b9c | 2011-07-01 17:56:50 -0500 | [diff] [blame] | 37 | | user, PHP under CGI with Apache suEXEC, etc.). Octal values should |
Derek Allard | 2067d1a | 2008-11-13 22:59:24 +0000 | [diff] [blame] | 38 | | always be used to set the mode correctly. |
| 39 | | |
| 40 | */ |
| 41 | define('FILE_READ_MODE', 0644); |
| 42 | define('FILE_WRITE_MODE', 0666); |
| 43 | define('DIR_READ_MODE', 0755); |
| 44 | define('DIR_WRITE_MODE', 0777); |
| 45 | |
| 46 | /* |
| 47 | |-------------------------------------------------------------------------- |
| 48 | | File Stream Modes |
| 49 | |-------------------------------------------------------------------------- |
| 50 | | |
| 51 | | These modes are used when working with fopen()/popen() |
| 52 | | |
| 53 | */ |
| 54 | |
D. Marshall Lemcoe Jr. | 88dabf1 | 2012-09-03 01:46:30 -0300 | [diff] [blame] | 55 | define('FOPEN_READ', 'rb'); |
| 56 | define('FOPEN_READ_WRITE', 'r+b'); |
| 57 | define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care |
| 58 | define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care |
| 59 | define('FOPEN_WRITE_CREATE', 'ab'); |
| 60 | define('FOPEN_READ_WRITE_CREATE', 'a+b'); |
| 61 | define('FOPEN_WRITE_CREATE_STRICT', 'xb'); |
| 62 | define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b'); |
Derek Allard | 2067d1a | 2008-11-13 22:59:24 +0000 | [diff] [blame] | 63 | |
Timothy Warren | 9a902cb | 2011-10-18 04:06:29 -0400 | [diff] [blame] | 64 | /* |
| 65 | |-------------------------------------------------------------------------- |
| 66 | | Display Debug backtrace |
| 67 | |-------------------------------------------------------------------------- |
| 68 | | |
Andrey Andreev | e734b38 | 2012-03-26 13:42:36 +0300 | [diff] [blame] | 69 | | If set to TRUE, a backtrace will be displayed along with php errors. If |
| 70 | | error_reporting is disabled, the backtrace will not display, regardless |
Timothy Warren | 9a902cb | 2011-10-18 04:06:29 -0400 | [diff] [blame] | 71 | | of this setting |
| 72 | | |
| 73 | */ |
Timothy Warren | 5160cc9 | 2011-10-18 06:50:06 -0400 | [diff] [blame] | 74 | define('SHOW_DEBUG_BACKTRACE', TRUE); |
Timothy Warren | 9a902cb | 2011-10-18 04:06:29 -0400 | [diff] [blame] | 75 | |
Daniel Hunsaker | 3b5b7f4 | 2013-02-22 19:17:56 -0700 | [diff] [blame^] | 76 | /* |
| 77 | |-------------------------------------------------------------------------- |
| 78 | | Exit Status Codes |
| 79 | |-------------------------------------------------------------------------- |
| 80 | | |
| 81 | | Used to indicate the conditions under which the script is exit()ing. |
| 82 | | While there is no universal standard for error codes, there are some |
| 83 | | broad conventions. Three such conventions are presented below, for |
| 84 | | those who wish to make use of them. The CodeIgniter defaults were |
| 85 | | chosen for the least overlap with these conventions, while still |
| 86 | | leaving room for others to be defined in future versions and user |
| 87 | | applications. The CodeIgniter values are defined last so you can |
| 88 | | set them to values used by any of the other conventions, and do so |
| 89 | | by name instead of value. |
| 90 | | |
| 91 | */ |
| 92 | |
| 93 | /* |
| 94 | * standard C/C++ library (stdlibc): |
| 95 | */ |
| 96 | /* |
| 97 | define('LIBC_EXIT_SUCCESS', 0); |
| 98 | define('LIBC_EXIT_FAILURE', 1); // generic errors |
| 99 | */ |
| 100 | |
| 101 | /* |
| 102 | * BSD sysexits.h |
| 103 | */ |
| 104 | /* |
| 105 | define('SYS_EX_OK', 0); // successful termination |
| 106 | define('SYS_EX_USAGE', 64); // command line usage error |
| 107 | define('SYS_EX_DATAERR', 65); // data format error |
| 108 | define('SYS_EX_NOINPUT', 66); // cannot open input |
| 109 | define('SYS_EX_NOUSER', 67); // specified user unknown |
| 110 | define('SYS_EX_NOHOST', 68); // specified host name unknown |
| 111 | define('SYS_EX_UNAVAILABLE', 69); // service unavailable |
| 112 | define('SYS_EX_SOFTWARE', 70); // internal software error |
| 113 | define('SYS_EX_OSERR', 71); // system error (e.g., can't fork) |
| 114 | define('SYS_EX_OSFILE', 72); // critical OS file missing |
| 115 | define('SYS_EX_CANTCREAT', 73); // can't create (user) output file |
| 116 | define('SYS_EX_IOERR', 74); // input/output error |
| 117 | define('SYS_EX_TEMPFAIL', 75); // temporary failure; user is invited to retry |
| 118 | define('SYS_EX_PROTOCOL', 76); // remote error in protocol |
| 119 | define('SYS_EX_NOPERM', 77); // permission denied |
| 120 | define('SYS_EX_CONFIG', 78); // configuration error |
| 121 | */ |
| 122 | |
| 123 | /* |
| 124 | * Bash scripting |
| 125 | */ |
| 126 | /* |
| 127 | define('BASH_EXIT_SUCCESS', 0); |
| 128 | define('BASH_EXIT_ERROR', 1); |
| 129 | define('BASH_EXIT_BUILTIN_MISUSE', 2); |
| 130 | define('BASH_EXIT_CANT_EXEC', 126); |
| 131 | define('BASH_EXIT_CMD_NOT_FOUND', 127); |
| 132 | define('BASH_EXIT_INVALID_EXIT', 128); |
| 133 | define('BASH_EXIT_SIG_HUP', 129); |
| 134 | define('BASH_EXIT_SIG_INT', 130); |
| 135 | define('BASH_EXIT_SIG_QUIT', 131); |
| 136 | define('BASH_EXIT_SIG_ILL', 132); |
| 137 | define('BASH_EXIT_SIG_TRAP', 133); |
| 138 | define('BASH_EXIT_SIG_ABRT', 134); |
| 139 | define('BASH_EXIT_SIG_BUS', 135); |
| 140 | define('BASH_EXIT_SIG_FPE', 136); |
| 141 | define('BASH_EXIT_SIG_KILL', 137); |
| 142 | define('BASH_EXIT_SIG_USR1', 138); |
| 143 | define('BASH_EXIT_SIG_SEGV', 139); |
| 144 | define('BASH_EXIT_SIG_USR2', 140); |
| 145 | define('BASH_EXIT_SIG_PIPE', 141); |
| 146 | define('BASH_EXIT_SIG_ALRM', 142); |
| 147 | define('BASH_EXIT_SIG_TERM', 143); |
| 148 | define('BASH_EXIT_SIG_STKFLT', 144); |
| 149 | define('BASH_EXIT_SIG_CHLD', 145); |
| 150 | define('BASH_EXIT_SIG_CONT', 146); |
| 151 | define('BASH_EXIT_SIG_STOP', 147); |
| 152 | define('BASH_EXIT_SIG_TSTP', 148); |
| 153 | define('BASH_EXIT_SIG_TTIN', 149); |
| 154 | define('BASH_EXIT_SIG_TTOU', 150); |
| 155 | define('BASH_EXIT_SIG_URG', 151); |
| 156 | define('BASH_EXIT_SIG_XCPU', 152); |
| 157 | define('BASH_EXIT_SIG_XFSZ', 153); |
| 158 | define('BASH_EXIT_SIG_VTALRM', 154); |
| 159 | define('BASH_EXIT_SIG_PROF', 155); |
| 160 | define('BASH_EXIT_SIG_WINCH', 156); |
| 161 | define('BASH_EXIT_SIG_IO', 157); |
| 162 | define('BASH_EXIT_SIG_PWR', 158); |
| 163 | define('BASH_EXIT_SIG_SYS', 159); |
| 164 | */ |
| 165 | /* |
| 166 | * BASH_EXIT_OUTOFRANGE would be 255, and mean an exit status code beyond |
| 167 | * the range of 0-255 was given. However, this code CANNOT BE USED IN PHP, |
| 168 | * so it isn't actually defined, even in a comment. |
| 169 | */ |
| 170 | |
| 171 | /* |
| 172 | * CodeIgniter defaults |
| 173 | */ |
| 174 | define('EXIT_SUCCESS', 0); // no errors |
| 175 | define('EXIT_FAILURE', 1); // generic error |
| 176 | define('EXIT_CONFIG', 3); // configuration error |
| 177 | define('EXIT_404', 4); // file not found; convenience value |
| 178 | define('EXIT_UNK_FILE', 4); // file not found |
| 179 | define('EXIT_UNK_CLASS', 5); // unknown class |
| 180 | define('EXIT_UNK_MEMBER', 6); // unknown class member |
| 181 | define('EXIT_USER_INPUT', 7); // invalid user input |
| 182 | define('EXIT_DATABASE', 8); // database error |
| 183 | define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code |
| 184 | define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code |
| 185 | |
Derek Allard | 2067d1a | 2008-11-13 22:59:24 +0000 | [diff] [blame] | 186 | |
| 187 | /* End of file constants.php */ |
Derek Jones | f0b3994 | 2010-03-25 10:08:20 -0500 | [diff] [blame] | 188 | /* Location: ./application/config/constants.php */ |