MediaWiki REL1_34
Defines.php
Go to the documentation of this file.
1<?php
23require_once __DIR__ . '/libs/mime/defines.php';
24require_once __DIR__ . '/libs/rdbms/defines.php';
25
27
39define( 'MW_VERSION', '1.34.4' );
40
41# Obsolete aliases
42
47define( 'LIST_COMMA', IDatabase::LIST_COMMA );
48define( 'LIST_AND', IDatabase::LIST_AND );
49define( 'LIST_SET', IDatabase::LIST_SET );
50define( 'LIST_NAMES', IDatabase::LIST_NAMES );
51define( 'LIST_OR', IDatabase::LIST_OR );
57define( 'NS_MEDIA', -2 );
58define( 'NS_SPECIAL', -1 );
69define( 'NS_MAIN', 0 );
70define( 'NS_TALK', 1 );
71define( 'NS_USER', 2 );
72define( 'NS_USER_TALK', 3 );
73define( 'NS_PROJECT', 4 );
74define( 'NS_PROJECT_TALK', 5 );
75define( 'NS_FILE', 6 );
76define( 'NS_FILE_TALK', 7 );
77define( 'NS_MEDIAWIKI', 8 );
78define( 'NS_MEDIAWIKI_TALK', 9 );
79define( 'NS_TEMPLATE', 10 );
80define( 'NS_TEMPLATE_TALK', 11 );
81define( 'NS_HELP', 12 );
82define( 'NS_HELP_TALK', 13 );
83define( 'NS_CATEGORY', 14 );
84define( 'NS_CATEGORY_TALK', 15 );
90define( 'CACHE_ANYTHING', -1 ); // Use anything, as long as it works
91define( 'CACHE_NONE', 0 ); // Do not cache
92define( 'CACHE_DB', 1 ); // Store cache objects in the DB
93define( 'CACHE_MEMCACHED', 2 ); // MemCached, must specify servers in $wgMemCacheServers
94define( 'CACHE_ACCEL', 3 ); // APC or WinCache
100define( 'AV_NO_VIRUS', 0 ); # scan ok, no virus found
101define( 'AV_VIRUS_FOUND', 1 ); # virus found!
102define( 'AV_SCAN_ABORTED', -1 ); # scan aborted, the file is probably immune
103define( 'AV_SCAN_FAILED', false ); # scan failed (scanner not found or error in scanner)
111define( 'ALF_PRELOAD_LINKS', 1 ); // unused
112define( 'ALF_PRELOAD_EXISTENCE', 2 ); // unused
113define( 'ALF_NO_LINK_LOCK', 4 ); // unused
114define( 'ALF_NO_BLOCK_LOCK', 8 ); // unused
121define( 'MW_DATE_DEFAULT', 'default' );
122define( 'MW_DATE_MDY', 'mdy' );
123define( 'MW_DATE_DMY', 'dmy' );
124define( 'MW_DATE_YMD', 'ymd' );
125define( 'MW_DATE_ISO', 'ISO 8601' );
131define( 'RC_EDIT', 0 );
132define( 'RC_NEW', 1 );
133define( 'RC_LOG', 3 );
134define( 'RC_EXTERNAL', 5 );
135define( 'RC_CATEGORIZE', 6 );
141define( 'EDIT_NEW', 1 );
142define( 'EDIT_UPDATE', 2 );
143define( 'EDIT_MINOR', 4 );
144define( 'EDIT_SUPPRESS_RC', 8 );
145define( 'EDIT_FORCE_BOT', 16 );
146define( 'EDIT_DEFER_UPDATES', 32 ); // Unused since 1.27
147define( 'EDIT_AUTOSUMMARY', 64 );
148define( 'EDIT_INTERNAL', 128 );
162
173define( 'OT_HTML', 1 );
174define( 'OT_WIKI', 2 );
175define( 'OT_PREPROCESS', 3 );
176define( 'OT_MSG', 3 ); // b/c alias for OT_PREPROCESS
177define( 'OT_PLAIN', 4 );
186define( 'SFH_NO_HASH', 1 );
187define( 'SFH_OBJECT_ARGS', 2 );
194define( 'APCOND_EDITCOUNT', 1 );
195define( 'APCOND_AGE', 2 );
197define( 'APCOND_INGROUPS', 4 );
198define( 'APCOND_ISIP', 5 );
199define( 'APCOND_IPINRANGE', 6 );
200define( 'APCOND_AGE_FROM_EDIT', 7 );
201define( 'APCOND_BLOCKED', 8 );
202define( 'APCOND_ISBOT', 9 );
208define( 'PROTO_HTTP', 'http://' );
209define( 'PROTO_HTTPS', 'https://' );
210define( 'PROTO_RELATIVE', '//' );
211define( 'PROTO_CURRENT', null );
212define( 'PROTO_CANONICAL', 1 );
213define( 'PROTO_INTERNAL', 2 );
224define( 'CONTENT_MODEL_WIKITEXT', 'wikitext' );
225define( 'CONTENT_MODEL_JAVASCRIPT', 'javascript' );
226define( 'CONTENT_MODEL_CSS', 'css' );
227define( 'CONTENT_MODEL_TEXT', 'text' );
228define( 'CONTENT_MODEL_JSON', 'json' );
238// wikitext
239define( 'CONTENT_FORMAT_WIKITEXT', 'text/x-wiki' );
240// for js pages
241define( 'CONTENT_FORMAT_JAVASCRIPT', 'text/javascript' );
242// for css pages
243define( 'CONTENT_FORMAT_CSS', 'text/css' );
244// for future use, e.g. with some plain-html messages.
245define( 'CONTENT_FORMAT_TEXT', 'text/plain' );
246// for future use, e.g. with some plain-html messages.
247define( 'CONTENT_FORMAT_HTML', 'text/html' );
248// for future use with the api and for extensions
249define( 'CONTENT_FORMAT_SERIALIZED', 'application/vnd.php.serialized' );
250// for future use with the api, and for use by extensions
251define( 'CONTENT_FORMAT_JSON', 'application/json' );
252// for future use with the api, and for use by extensions
253define( 'CONTENT_FORMAT_XML', 'application/xml' );
259define( 'SHELL_MAX_ARG_STRLEN', '100000' );
273define( 'SCHEMA_COMPAT_WRITE_OLD', 0x01 );
274define( 'SCHEMA_COMPAT_READ_OLD', 0x02 );
275define( 'SCHEMA_COMPAT_WRITE_NEW', 0x10 );
276define( 'SCHEMA_COMPAT_READ_NEW', 0x20 );
304define( 'MIGRATION_OLD', 0x00000000 | SCHEMA_COMPAT_OLD );
307define( 'MIGRATION_NEW', 0x30000000 | SCHEMA_COMPAT_NEW );
317define( 'XML_DUMP_SCHEMA_VERSION_10', '0.10' );
318define( 'XML_DUMP_SCHEMA_VERSION_11', '0.11' );
const MW_SUPPORTS_RESOURCE_MODULES
Support for $wgResourceModules.
Definition Defines.php:161
const SCHEMA_COMPAT_WRITE_BOTH
Definition Defines.php:277
const APCOND_BLOCKED
Definition Defines.php:201
const CONTENT_FORMAT_JAVASCRIPT
Definition Defines.php:241
const SCHEMA_COMPAT_OLD
Definition Defines.php:279
const OT_WIKI
Definition Defines.php:174
const SFH_NO_HASH
Definition Defines.php:186
const ALF_PRELOAD_LINKS
Definition Defines.php:111
const CONTENT_FORMAT_HTML
Definition Defines.php:247
const CONTENT_FORMAT_JSON
Definition Defines.php:251
const SCHEMA_COMPAT_READ_NEW
Definition Defines.php:276
const PROTO_CANONICAL
Definition Defines.php:212
const EDIT_FORCE_BOT
Definition Defines.php:145
const APCOND_AGE
Definition Defines.php:195
const ALF_NO_BLOCK_LOCK
Definition Defines.php:114
const ALF_PRELOAD_EXISTENCE
Definition Defines.php:112
const APCOND_EMAILCONFIRMED
Definition Defines.php:196
const SCHEMA_COMPAT_READ_BOTH
Definition Defines.php:278
const SFH_OBJECT_ARGS
Definition Defines.php:187
const EDIT_DEFER_UPDATES
Definition Defines.php:146
const EDIT_INTERNAL
Definition Defines.php:148
const EDIT_UPDATE
Definition Defines.php:142
const PROTO_HTTPS
Definition Defines.php:209
const SCHEMA_COMPAT_WRITE_OLD
Definition Defines.php:273
const APCOND_IPINRANGE
Definition Defines.php:199
const MW_SUPPORTS_CONTENTHANDLER
Definition Defines.php:156
const CONTENT_MODEL_CSS
Definition Defines.php:226
const APCOND_INGROUPS
Definition Defines.php:197
const RC_NEW
Definition Defines.php:132
const PROTO_CURRENT
Definition Defines.php:211
const MW_EDITFILTERMERGED_SUPPORTS_API
Definition Defines.php:157
const PROTO_INTERNAL
Definition Defines.php:213
const CONTENT_FORMAT_TEXT
Definition Defines.php:245
const APCOND_ISBOT
Definition Defines.php:202
const APCOND_AGE_FROM_EDIT
Definition Defines.php:200
const EDIT_SUPPRESS_RC
Definition Defines.php:144
const MW_DATE_MDY
Definition Defines.php:122
const CONTENT_FORMAT_CSS
Definition Defines.php:243
const XML_DUMP_SCHEMA_VERSION_11
Definition Defines.php:318
const OT_PLAIN
Definition Defines.php:177
const MW_DATE_DMY
Definition Defines.php:123
const MW_SUPPORTS_LOCALISATIONCACHE
Definition Defines.php:155
const OT_PREPROCESS
Definition Defines.php:175
const APCOND_ISIP
Definition Defines.php:198
const CONTENT_MODEL_WIKITEXT
Definition Defines.php:224
const MIGRATION_WRITE_NEW
Definition Defines.php:306
const SCHEMA_COMPAT_READ_OLD
Definition Defines.php:274
const XML_DUMP_SCHEMA_VERSION_10
Definition Defines.php:317
const CONTENT_MODEL_JSON
Definition Defines.php:228
const MIGRATION_NEW
Definition Defines.php:307
const RC_LOG
Definition Defines.php:133
const RC_EXTERNAL
Definition Defines.php:134
const MW_DATE_YMD
Definition Defines.php:124
const CONTENT_FORMAT_WIKITEXT
Definition Defines.php:239
const PROTO_HTTP
Definition Defines.php:208
const OT_HTML
Definition Defines.php:173
const CONTENT_MODEL_TEXT
Definition Defines.php:227
const SCHEMA_COMPAT_WRITE_NEW
Definition Defines.php:275
const SHELL_MAX_ARG_STRLEN
Definition Defines.php:259
const APCOND_EDITCOUNT
Definition Defines.php:194
const MW_DATE_ISO
Definition Defines.php:125
const PROTO_RELATIVE
Definition Defines.php:210
const MW_DATE_DEFAULT
Definition Defines.php:121
const SCHEMA_COMPAT_NEW
Definition Defines.php:280
const CONTENT_FORMAT_SERIALIZED
Definition Defines.php:249
const MIGRATION_WRITE_BOTH
Definition Defines.php:305
const RC_EDIT
Definition Defines.php:131
const MIGRATION_OLD
Definition Defines.php:304
const MW_SUPPORTS_PARSERFIRSTCALLINIT
Definition Defines.php:154
const EDIT_MINOR
Definition Defines.php:143
const CONTENT_FORMAT_XML
Definition Defines.php:253
const CONTENT_MODEL_JAVASCRIPT
Definition Defines.php:225
const EDIT_AUTOSUMMARY
Definition Defines.php:147
const ALF_NO_LINK_LOCK
Definition Defines.php:113
const OT_MSG
Definition Defines.php:176
const EDIT_NEW
Definition Defines.php:141
const RC_CATEGORIZE
Definition Defines.php:135
Basic database interface for live and lazy-loaded relation database handles.
Definition IDatabase.php:38