phpBB
Statistics
| Revision:

root / trunk / phpBB / includes / constants.php

History | View | Annotate | Download (8.8 kB)

1
<?php
2
/**
3
*
4
* @package phpBB3
5
* @copyright (c) 2005 phpBB Group
6
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
7
*
8
*/
9
10
/**
11
* @ignore
12
*/
13
if (!defined('IN_PHPBB'))
14
{
15
        exit;
16
}
17
18
/**
19
* valid external constants:
20
* PHPBB_MSG_HANDLER
21
* PHPBB_DB_NEW_LINK
22
* PHPBB_ROOT_PATH
23
* PHPBB_ADMIN_PATH
24
*/
25
26
// phpBB Version
27
define('PHPBB_VERSION', '3.1.0-dev');
28
29
// QA-related
30
// define('PHPBB_QA', 1);
31
32
// User related
33
define('ANONYMOUS', 1);
34
35
define('USER_ACTIVATION_NONE', 0);
36
define('USER_ACTIVATION_SELF', 1);
37
define('USER_ACTIVATION_ADMIN', 2);
38
define('USER_ACTIVATION_DISABLE', 3);
39
40
define('AVATAR_UPLOAD', 1);
41
define('AVATAR_REMOTE', 2);
42
define('AVATAR_GALLERY', 3);
43
44
define('USER_NORMAL', 0);
45
define('USER_INACTIVE', 1);
46
define('USER_IGNORE', 2);
47
define('USER_FOUNDER', 3);
48
49
define('INACTIVE_REGISTER', 1);
50
define('INACTIVE_PROFILE', 2);
51
define('INACTIVE_MANUAL', 3);
52
define('INACTIVE_REMIND', 4);
53
54
// ACL
55
define('ACL_NEVER', 0);
56
define('ACL_YES', 1);
57
define('ACL_NO', -1);
58
59
// Login error codes
60
define('LOGIN_CONTINUE', 1);
61
define('LOGIN_BREAK', 2);
62
define('LOGIN_SUCCESS', 3);
63
define('LOGIN_SUCCESS_CREATE_PROFILE', 20);
64
define('LOGIN_ERROR_USERNAME', 10);
65
define('LOGIN_ERROR_PASSWORD', 11);
66
define('LOGIN_ERROR_ACTIVE', 12);
67
define('LOGIN_ERROR_ATTEMPTS', 13);
68
define('LOGIN_ERROR_EXTERNAL_AUTH', 14);
69
define('LOGIN_ERROR_PASSWORD_CONVERT', 15);
70
71
// Maximum login attempts
72
// The value is arbitrary, but it has to fit into the user_login_attempts field.
73
define('LOGIN_ATTEMPTS_MAX', 100);
74
75
// Group settings
76
define('GROUP_OPEN', 0);
77
define('GROUP_CLOSED', 1);
78
define('GROUP_HIDDEN', 2);
79
define('GROUP_SPECIAL', 3);
80
define('GROUP_FREE', 4);
81
82
// Forum/Topic states
83
define('FORUM_CAT', 0);
84
define('FORUM_POST', 1);
85
define('FORUM_LINK', 2);
86
define('ITEM_UNLOCKED', 0);
87
define('ITEM_LOCKED', 1);
88
define('ITEM_MOVED', 2);
89
90
// Forum Flags
91
define('FORUM_FLAG_LINK_TRACK', 1);
92
define('FORUM_FLAG_PRUNE_POLL', 2);
93
define('FORUM_FLAG_PRUNE_ANNOUNCE', 4);
94
define('FORUM_FLAG_PRUNE_STICKY', 8);
95
define('FORUM_FLAG_ACTIVE_TOPICS', 16);
96
define('FORUM_FLAG_POST_REVIEW', 32);
97
define('FORUM_FLAG_QUICK_REPLY', 64);
98
99
// Forum Options... sequential order. Modifications should begin at number 10 (number 29 is maximum)
100
define('FORUM_OPTION_FEED_NEWS', 1);
101
define('FORUM_OPTION_FEED_EXCLUDE', 2);
102
103
// Optional text flags
104
define('OPTION_FLAG_BBCODE', 1);
105
define('OPTION_FLAG_SMILIES', 2);
106
define('OPTION_FLAG_LINKS', 4);
107
108
// Topic types
109
define('POST_NORMAL', 0);
110
define('POST_STICKY', 1);
111
define('POST_ANNOUNCE', 2);
112
define('POST_GLOBAL', 3);
113
114
// Lastread types
115
define('TRACK_NORMAL', 0);
116
define('TRACK_POSTED', 1);
117
118
// Notify methods
119
define('NOTIFY_EMAIL', 0);
120
define('NOTIFY_IM', 1);
121
define('NOTIFY_BOTH', 2);
122
123
// Notify status
124
define('NOTIFY_YES', 0);
125
define('NOTIFY_NO', 1);
126
127
// Email Priority Settings
128
define('MAIL_LOW_PRIORITY', 4);
129
define('MAIL_NORMAL_PRIORITY', 3);
130
define('MAIL_HIGH_PRIORITY', 2);
131
132
// Log types
133
define('LOG_ADMIN', 0);
134
define('LOG_MOD', 1);
135
define('LOG_CRITICAL', 2);
136
define('LOG_USERS', 3);
137
138
// Private messaging - Do NOT change these values
139
define('PRIVMSGS_HOLD_BOX', -4);
140
define('PRIVMSGS_NO_BOX', -3);
141
define('PRIVMSGS_OUTBOX', -2);
142
define('PRIVMSGS_SENTBOX', -1);
143
define('PRIVMSGS_INBOX', 0);
144
145
// Full Folder Actions
146
define('FULL_FOLDER_NONE', -3);
147
define('FULL_FOLDER_DELETE', -2);
148
define('FULL_FOLDER_HOLD', -1);
149
150
// Download Modes - Attachments
151
define('INLINE_LINK', 1);
152
// This mode is only used internally to allow modders extending the attachment functionality
153
define('PHYSICAL_LINK', 2);
154
155
// Confirm types
156
define('CONFIRM_REG', 1);
157
define('CONFIRM_LOGIN', 2);
158
define('CONFIRM_POST', 3);
159
160
// Categories - Attachments
161
define('ATTACHMENT_CATEGORY_NONE', 0);
162
define('ATTACHMENT_CATEGORY_IMAGE', 1); // Inline Images
163
define('ATTACHMENT_CATEGORY_WM', 2); // Windows Media Files - Streaming
164
define('ATTACHMENT_CATEGORY_RM', 3); // Real Media Files - Streaming
165
define('ATTACHMENT_CATEGORY_THUMB', 4); // Not used within the database, only while displaying posts
166
define('ATTACHMENT_CATEGORY_FLASH', 5); // Flash/SWF files
167
define('ATTACHMENT_CATEGORY_QUICKTIME', 6); // Quicktime/Mov files
168
169
// BBCode UID length
170
define('BBCODE_UID_LEN', 8);
171
172
// Number of core BBCodes
173
define('NUM_CORE_BBCODES', 12);
174
175
// BBCode hard limit
176
define('BBCODE_LIMIT', 1511);
177
178
// Smiley hard limit
179
define('SMILEY_LIMIT', 1000);
180
181
// Magic url types
182
define('MAGIC_URL_EMAIL', 1);
183
define('MAGIC_URL_FULL', 2);
184
define('MAGIC_URL_LOCAL', 3);
185
define('MAGIC_URL_WWW', 4);
186
187
// Profile Field Types
188
define('FIELD_INT', 1);
189
define('FIELD_STRING', 2);
190
define('FIELD_TEXT', 3);
191
define('FIELD_BOOL', 4);
192
define('FIELD_DROPDOWN', 5);
193
define('FIELD_DATE', 6);
194
195
// referer validation
196
define('REFERER_VALIDATE_NONE', 0);
197
define('REFERER_VALIDATE_HOST', 1);
198
define('REFERER_VALIDATE_PATH', 2);
199
200
// phpbb_chmod() permissions
201
@define('CHMOD_ALL', 7);
202
@define('CHMOD_READ', 4);
203
@define('CHMOD_WRITE', 2);
204
@define('CHMOD_EXECUTE', 1);
205
206
// Captcha code length
207
define('CAPTCHA_MIN_CHARS', 4);
208
define('CAPTCHA_MAX_CHARS', 7);
209
210
// Additional constants
211
define('VOTE_CONVERTED', 127);
212
213
// Table names
214
define('ACL_GROUPS_TABLE',                        $table_prefix . 'acl_groups');
215
define('ACL_OPTIONS_TABLE',                        $table_prefix . 'acl_options');
216
define('ACL_ROLES_DATA_TABLE',                $table_prefix . 'acl_roles_data');
217
define('ACL_ROLES_TABLE',                        $table_prefix . 'acl_roles');
218
define('ACL_USERS_TABLE',                        $table_prefix . 'acl_users');
219
define('ATTACHMENTS_TABLE',                        $table_prefix . 'attachments');
220
define('BANLIST_TABLE',                                $table_prefix . 'banlist');
221
define('BBCODES_TABLE',                                $table_prefix . 'bbcodes');
222
define('BOOKMARKS_TABLE',                        $table_prefix . 'bookmarks');
223
define('BOTS_TABLE',                                $table_prefix . 'bots');
224
define('CONFIG_TABLE',                                $table_prefix . 'config');
225
define('CONFIRM_TABLE',                                $table_prefix . 'confirm');
226
define('DISALLOW_TABLE',                        $table_prefix . 'disallow');
227
define('DRAFTS_TABLE',                                $table_prefix . 'drafts');
228
define('EXT_TABLE',                                        $table_prefix . 'ext');
229
define('EXTENSIONS_TABLE',                        $table_prefix . 'extensions');
230
define('EXTENSION_GROUPS_TABLE',        $table_prefix . 'extension_groups');
231
define('FORUMS_TABLE',                                $table_prefix . 'forums');
232
define('FORUMS_ACCESS_TABLE',                $table_prefix . 'forums_access');
233
define('FORUMS_TRACK_TABLE',                $table_prefix . 'forums_track');
234
define('FORUMS_WATCH_TABLE',                $table_prefix . 'forums_watch');
235
define('GROUPS_TABLE',                                $table_prefix . 'groups');
236
define('ICONS_TABLE',                                $table_prefix . 'icons');
237
define('LANG_TABLE',                                $table_prefix . 'lang');
238
define('LOG_TABLE',                                        $table_prefix . 'log');
239
define('LOGIN_ATTEMPT_TABLE',                $table_prefix . 'login_attempts');
240
define('MODERATOR_CACHE_TABLE',                $table_prefix . 'moderator_cache');
241
define('MODULES_TABLE',                                $table_prefix . 'modules');
242
define('POLL_OPTIONS_TABLE',                $table_prefix . 'poll_options');
243
define('POLL_VOTES_TABLE',                        $table_prefix . 'poll_votes');
244
define('POSTS_TABLE',                                $table_prefix . 'posts');
245
define('PRIVMSGS_TABLE',                        $table_prefix . 'privmsgs');
246
define('PRIVMSGS_FOLDER_TABLE',                $table_prefix . 'privmsgs_folder');
247
define('PRIVMSGS_RULES_TABLE',                $table_prefix . 'privmsgs_rules');
248
define('PRIVMSGS_TO_TABLE',                        $table_prefix . 'privmsgs_to');
249
define('PROFILE_FIELDS_TABLE',                $table_prefix . 'profile_fields');
250
define('PROFILE_FIELDS_DATA_TABLE',        $table_prefix . 'profile_fields_data');
251
define('PROFILE_FIELDS_LANG_TABLE',        $table_prefix . 'profile_fields_lang');
252
define('PROFILE_LANG_TABLE',                $table_prefix . 'profile_lang');
253
define('RANKS_TABLE',                                $table_prefix . 'ranks');
254
define('REPORTS_TABLE',                                $table_prefix . 'reports');
255
define('REPORTS_REASONS_TABLE',                $table_prefix . 'reports_reasons');
256
define('SEARCH_RESULTS_TABLE',                $table_prefix . 'search_results');
257
define('SEARCH_WORDLIST_TABLE',                $table_prefix . 'search_wordlist');
258
define('SEARCH_WORDMATCH_TABLE',        $table_prefix . 'search_wordmatch');
259
define('SESSIONS_TABLE',                        $table_prefix . 'sessions');
260
define('SESSIONS_KEYS_TABLE',                $table_prefix . 'sessions_keys');
261
define('SITELIST_TABLE',                        $table_prefix . 'sitelist');
262
define('SMILIES_TABLE',                                $table_prefix . 'smilies');
263
define('STYLES_TABLE',                                $table_prefix . 'styles');
264
define('STYLES_TEMPLATE_TABLE',                $table_prefix . 'styles_template');
265
define('STYLES_TEMPLATE_DATA_TABLE',$table_prefix . 'styles_template_data');
266
define('STYLES_THEME_TABLE',                $table_prefix . 'styles_theme');
267
define('STYLES_IMAGESET_TABLE',                $table_prefix . 'styles_imageset');
268
define('STYLES_IMAGESET_DATA_TABLE',$table_prefix . 'styles_imageset_data');
269
define('TOPICS_TABLE',                                $table_prefix . 'topics');
270
define('TOPICS_POSTED_TABLE',                $table_prefix . 'topics_posted');
271
define('TOPICS_TRACK_TABLE',                $table_prefix . 'topics_track');
272
define('TOPICS_WATCH_TABLE',                $table_prefix . 'topics_watch');
273
define('USER_GROUP_TABLE',                        $table_prefix . 'user_group');
274
define('USERS_TABLE',                                $table_prefix . 'users');
275
define('WARNINGS_TABLE',                        $table_prefix . 'warnings');
276
define('WORDS_TABLE',                                $table_prefix . 'words');
277
define('ZEBRA_TABLE',                                $table_prefix . 'zebra');
278
279
// Additional tables
280