MediaWiki  REL1_22
Defines.php
Go to the documentation of this file.
00001 <?php
00034 define( 'MW_SPECIALPAGE_VERSION', 2 );
00035 
00039 define( 'DBO_DEBUG', 1 );
00040 define( 'DBO_NOBUFFER', 2 );
00041 define( 'DBO_IGNORE', 4 );
00042 define( 'DBO_TRX', 8 ); // automatically start transaction on first query
00043 define( 'DBO_DEFAULT', 16 );
00044 define( 'DBO_PERSISTENT', 32 );
00045 define( 'DBO_SYSDBA', 64 ); //for oracle maintenance
00046 define( 'DBO_DDLMODE', 128 ); // when using schema files: mostly for Oracle
00047 define( 'DBO_SSL', 256 );
00048 define( 'DBO_COMPRESS', 512 );
00055 define( 'DB_SLAVE', -1 );     # Read from the slave (or only server)
00056 define( 'DB_MASTER', -2 );    # Write to master (or only server)
00057 
00059 # Obsolete aliases
00060 define( 'DB_READ', -1 );
00061 define( 'DB_WRITE', -2 );
00062 define( 'DB_LAST', -3 ); # deprecated since 2008, usage throws exception
00063 
00067 define( 'NS_MEDIA', -2 );
00068 define( 'NS_SPECIAL', -1 );
00079 define( 'NS_MAIN', 0 );
00080 define( 'NS_TALK', 1 );
00081 define( 'NS_USER', 2 );
00082 define( 'NS_USER_TALK', 3 );
00083 define( 'NS_PROJECT', 4 );
00084 define( 'NS_PROJECT_TALK', 5 );
00085 define( 'NS_FILE', 6 );
00086 define( 'NS_FILE_TALK', 7 );
00087 define( 'NS_MEDIAWIKI', 8 );
00088 define( 'NS_MEDIAWIKI_TALK', 9 );
00089 define( 'NS_TEMPLATE', 10 );
00090 define( 'NS_TEMPLATE_TALK', 11 );
00091 define( 'NS_HELP', 12 );
00092 define( 'NS_HELP_TALK', 13 );
00093 define( 'NS_CATEGORY', 14 );
00094 define( 'NS_CATEGORY_TALK', 15 );
00095 
00104 define( 'NS_IMAGE', NS_FILE );
00105 define( 'NS_IMAGE_TALK', NS_FILE_TALK );
00111 define( 'CACHE_ANYTHING', -1 );  // Use anything, as long as it works
00112 define( 'CACHE_NONE', 0 );       // Do not cache
00113 define( 'CACHE_DB', 1 );         // Store cache objects in the DB
00114 define( 'CACHE_MEMCACHED', 2 );  // MemCached, must specify servers in $wgMemCacheServers
00115 define( 'CACHE_ACCEL', 3 );      // APC, XCache or WinCache
00116 define( 'CACHE_DBA', 4 );        // Use PHP's DBA extension to store in a DBM-style database
00123 define( 'MEDIATYPE_UNKNOWN',    'UNKNOWN' );     // unknown format
00124 define( 'MEDIATYPE_BITMAP',     'BITMAP' );      // some bitmap image or image source (like psd, etc). Can't scale up.
00125 define( 'MEDIATYPE_DRAWING',    'DRAWING' );     // some vector drawing (SVG, WMF, PS, ...) or image source (oo-draw, etc). Can scale up.
00126 define( 'MEDIATYPE_AUDIO',      'AUDIO' );       // simple audio file (ogg, mp3, wav, midi, whatever)
00127 define( 'MEDIATYPE_VIDEO',      'VIDEO' );       // simple video file (ogg, mpg, etc; no not include formats here that may contain executable sections or scripts!)
00128 define( 'MEDIATYPE_MULTIMEDIA', 'MULTIMEDIA' );  // Scriptable Multimedia (flash, advanced video container formats, etc)
00129 define( 'MEDIATYPE_OFFICE',     'OFFICE' );      // Office Documents, Spreadsheets (office formats possibly containing apples, scripts, etc)
00130 define( 'MEDIATYPE_TEXT',       'TEXT' );        // Plain text (possibly containing program code or scripts)
00131 define( 'MEDIATYPE_EXECUTABLE', 'EXECUTABLE' );  // binary executable
00132 define( 'MEDIATYPE_ARCHIVE',    'ARCHIVE' );     // archive file (zip, tar, etc)
00138 define( 'AV_NO_VIRUS', 0 );  #scan ok, no virus found
00139 define( 'AV_VIRUS_FOUND', 1 );  #virus found!
00140 define( 'AV_SCAN_ABORTED', -1 );  #scan aborted, the file is probably immune
00141 define( 'AV_SCAN_FAILED', false );  #scan failed (scanner not found or error in scanner)
00148 define( 'ALF_PRELOAD_LINKS', 1 ); // unused
00149 define( 'ALF_PRELOAD_EXISTENCE', 2 ); // unused
00150 define( 'ALF_NO_LINK_LOCK', 4 );
00151 define( 'ALF_NO_BLOCK_LOCK', 8 );
00158 /*define( 'MW_DATE_DEFAULT', '0' );
00159 define( 'MW_DATE_MDY', '1' );
00160 define( 'MW_DATE_DMY', '2' );
00161 define( 'MW_DATE_YMD', '3' );
00162 define( 'MW_DATE_ISO', 'ISO 8601' );*/
00163 define( 'MW_DATE_DEFAULT', 'default' );
00164 define( 'MW_DATE_MDY', 'mdy' );
00165 define( 'MW_DATE_DMY', 'dmy' );
00166 define( 'MW_DATE_YMD', 'ymd' );
00167 define( 'MW_DATE_ISO', 'ISO 8601' );
00173 define( 'RC_EDIT', 0 );
00174 define( 'RC_NEW', 1 );
00175 define( 'RC_MOVE', 2 ); // obsolete
00176 define( 'RC_LOG', 3 );
00177 define( 'RC_MOVE_OVER_REDIRECT', 4 ); // obsolete
00178 define( 'RC_EXTERNAL', 5 );
00184 define( 'EDIT_NEW', 1 );
00185 define( 'EDIT_UPDATE', 2 );
00186 define( 'EDIT_MINOR', 4 );
00187 define( 'EDIT_SUPPRESS_RC', 8 );
00188 define( 'EDIT_FORCE_BOT', 16 );
00189 define( 'EDIT_DEFER_UPDATES', 32 );
00190 define( 'EDIT_AUTOSUMMARY', 64 );
00197 define( 'LIST_COMMA', 0 );
00198 define( 'LIST_AND', 1 );
00199 define( 'LIST_SET', 2 );
00200 define( 'LIST_NAMES', 3 );
00201 define( 'LIST_OR', 4 );
00207 require_once __DIR__ . '/normal/UtfNormalDefines.php';
00208 
00212 define( 'MW_SUPPORTS_EDITFILTERMERGED', 1 );
00213 define( 'MW_SUPPORTS_PARSERFIRSTCALLINIT', 1 );
00214 define( 'MW_SUPPORTS_LOCALISATIONCACHE', 1 );
00215 define( 'MW_SUPPORTS_CONTENTHANDLER', 1 );
00219 define( 'MW_SUPPORTS_RESOURCE_MODULES', 1 );
00220 
00225 define( 'OT_HTML', 1 );
00226 define( 'OT_WIKI', 2 );
00227 define( 'OT_PREPROCESS', 3 );
00228 define( 'OT_MSG', 3 );  // b/c alias for OT_PREPROCESS
00229 define( 'OT_PLAIN', 4 );
00235 define( 'SFH_NO_HASH', 1 );
00236 define( 'SFH_OBJECT_ARGS', 2 );
00242 define( 'RLH_FOR_UPDATE', 1 );
00243 
00248 define( 'APCOND_EDITCOUNT', 1 );
00249 define( 'APCOND_AGE', 2 );
00250 define( 'APCOND_EMAILCONFIRMED', 3 );
00251 define( 'APCOND_INGROUPS', 4 );
00252 define( 'APCOND_ISIP', 5 );
00253 define( 'APCOND_IPINRANGE', 6 );
00254 define( 'APCOND_AGE_FROM_EDIT', 7 );
00255 define( 'APCOND_BLOCKED', 8 );
00256 define( 'APCOND_ISBOT', 9 );
00262 define( 'PROTO_HTTP', 'http://' );
00263 define( 'PROTO_HTTPS', 'https://' );
00264 define( 'PROTO_RELATIVE', '//' );
00265 define( 'PROTO_CURRENT', null );
00266 define( 'PROTO_CANONICAL', 1 );
00267 define( 'PROTO_INTERNAL', 2 );
00278 define( 'CONTENT_MODEL_WIKITEXT', 'wikitext' );
00279 define( 'CONTENT_MODEL_JAVASCRIPT', 'javascript' );
00280 define( 'CONTENT_MODEL_CSS', 'css' );
00281 define( 'CONTENT_MODEL_TEXT', 'text' );
00291 define( 'CONTENT_FORMAT_WIKITEXT', 'text/x-wiki' ); // wikitext
00292 define( 'CONTENT_FORMAT_JAVASCRIPT', 'text/javascript' ); // for js pages
00293 define( 'CONTENT_FORMAT_CSS', 'text/css' );  // for css pages
00294 define( 'CONTENT_FORMAT_TEXT', 'text/plain' ); // for future use, e.g. with some plain-html messages.
00295 define( 'CONTENT_FORMAT_HTML', 'text/html' ); // for future use, e.g. with some plain-html messages.
00296 define( 'CONTENT_FORMAT_SERIALIZED', 'application/vnd.php.serialized' ); // for future use with the api and for extensions
00297 define( 'CONTENT_FORMAT_JSON', 'application/json' ); // for future use with the api, and for use by extensions
00298 define( 'CONTENT_FORMAT_XML', 'application/xml' ); // for future use with the api, and for use by extensions