BlueSpice MediaWiki master
 All Classes Namespaces Files Functions Variables Groups Pages
MediaWiki constants

Variables

const LIST_COMMA IDatabase::LIST_COMMA
 
const LIST_AND IDatabase::LIST_AND
 
const LIST_SET IDatabase::LIST_SET
 
const LIST_NAMES IDatabase::LIST_NAMES
 
const LIST_OR IDatabase::LIST_OR
 
const NS_MEDIA -2
 
const NS_SPECIAL -1
 
const NS_MAIN 0
 
const NS_TALK 1
 
const NS_USER 2
 
const NS_USER_TALK 3
 
const NS_PROJECT 4
 
const NS_PROJECT_TALK 5
 
const NS_FILE 6
 
const NS_FILE_TALK 7
 
const NS_MEDIAWIKI 8
 
const NS_MEDIAWIKI_TALK 9
 
const NS_TEMPLATE 10
 
const NS_TEMPLATE_TALK 11
 
const NS_HELP 12
 
const NS_HELP_TALK 13
 
const NS_CATEGORY 14
 
const NS_CATEGORY_TALK 15
 
const NS_IMAGE NS_FILE
 
const NS_IMAGE_TALK NS_FILE_TALK
 
const CACHE_ANYTHING -1
 
const CACHE_NONE 0
 
const CACHE_DB 1
 
const CACHE_MEMCACHED 2
 
const CACHE_ACCEL 3
 
const AV_NO_VIRUS 0
 
const AV_VIRUS_FOUND 1
 
const AV_SCAN_ABORTED -1
 
const AV_SCAN_FAILED false
 
const ALF_PRELOAD_LINKS 1
 
const ALF_PRELOAD_EXISTENCE 2
 
const ALF_NO_LINK_LOCK 4
 
const ALF_NO_BLOCK_LOCK 8
 
const MW_DATE_DEFAULT 'default'
 
const MW_DATE_MDY 'mdy'
 
const MW_DATE_DMY 'dmy'
 
const MW_DATE_YMD 'ymd'
 
const MW_DATE_ISO 'ISO 8601'
 
const RC_EDIT 0
 
const RC_NEW 1
 
const RC_LOG 3
 
const RC_EXTERNAL 5
 
const RC_CATEGORIZE 6
 
const EDIT_NEW 1
 
const EDIT_UPDATE 2
 
const EDIT_MINOR 4
 
const EDIT_SUPPRESS_RC 8
 
const EDIT_FORCE_BOT 16
 
const EDIT_DEFER_UPDATES 32
 
const EDIT_AUTOSUMMARY 64
 
const EDIT_INTERNAL 128
 
const MW_SUPPORTS_PARSERFIRSTCALLINIT 1
 
const MW_SUPPORTS_LOCALISATIONCACHE 1
 
const MW_SUPPORTS_CONTENTHANDLER 1
 
const MW_EDITFILTERMERGED_SUPPORTS_API 1
 
const OT_HTML 1
 
const OT_WIKI 2
 
const OT_PREPROCESS 3
 
const OT_MSG 3
 
const OT_PLAIN 4
 
const SFH_NO_HASH 1
 
const SFH_OBJECT_ARGS 2
 
const APCOND_EDITCOUNT 1
 
const APCOND_AGE 2
 
const APCOND_EMAILCONFIRMED 3
 
const APCOND_INGROUPS 4
 
const APCOND_ISIP 5
 
const APCOND_IPINRANGE 6
 
const APCOND_AGE_FROM_EDIT 7
 
const APCOND_BLOCKED 8
 
const APCOND_ISBOT 9
 
const PROTO_HTTP 'http://'
 
const PROTO_HTTPS 'https://'
 
const PROTO_RELATIVE '//'
 
const PROTO_CURRENT null
 
const PROTO_CANONICAL 1
 
const PROTO_INTERNAL 2
 
const CONTENT_MODEL_WIKITEXT 'wikitext'
 
const CONTENT_MODEL_JAVASCRIPT 'javascript'
 
const CONTENT_MODEL_CSS 'css'
 
const CONTENT_MODEL_TEXT 'text'
 
const CONTENT_MODEL_JSON 'json'
 
const CONTENT_FORMAT_WIKITEXT 'text/x-wiki'
 
const CONTENT_FORMAT_JAVASCRIPT 'text/javascript'
 
const CONTENT_FORMAT_CSS 'text/css'
 
const CONTENT_FORMAT_TEXT 'text/plain'
 
const CONTENT_FORMAT_HTML 'text/html'
 
const CONTENT_FORMAT_SERIALIZED 'application/vnd.php.serialized'
 
const CONTENT_FORMAT_JSON 'application/json'
 
const CONTENT_FORMAT_XML 'application/xml'
 
const SHELL_MAX_ARG_STRLEN '100000'
 
const MIGRATION_OLD 0
 
const MIGRATION_WRITE_BOTH 1
 
const MIGRATION_WRITE_NEW 2
 
const MIGRATION_NEW 3
 

Detailed Description

Variable Documentation

const ALF_PRELOAD_LINKS 1

Anti-lock flags Was used by $wgAntiLockFlags, which was removed with 1.25 Constants kept to not have warnings when used in LocalSettings

const APCOND_EDITCOUNT 1

Autopromote conditions (must be here and not in Autopromote.php, so that they're loaded for DefaultSettings.php before AutoLoader.php)

const AV_NO_VIRUS 0

Antivirus result codes, for use in $wgAntivirusSetup.

const CACHE_ANYTHING -1

Cache type

const CONTENT_FORMAT_WIKITEXT 'text/x-wiki'

Content formats, used by Content and ContentHandler. These should be MIME types, and will be exposed in the API and XML dumps.

Extensions are free to use the below formats, or define their own. It is recommended to stick with the conventions for MIME types.

const CONTENT_MODEL_WIKITEXT 'wikitext'

Content model ids, used by Content and ContentHandler. These IDs will be exposed in the API and XML dumps.

Extensions that define their own content model IDs should take care to avoid conflicts. Using the extension name as a prefix is recommended, for example 'myextension-somecontent'.

const EDIT_NEW 1

Article edit flags

const LIST_COMMA IDatabase::LIST_COMMA

Obsolete IDatabase::makeList() constants These are also available as Database class constants

const MIGRATION_OLD 0

Schema change migration flags.

Used as values of a feature flag for an orderly transition from an old schema to a new schema.

  • MIGRATION_OLD: Only read and write the old schema. The new schema need not even exist. This is used from when the patch is merged until the schema change is actually applied to the database.
  • MIGRATION_WRITE_BOTH: Write both the old and new schema. Read the new schema preferentially, falling back to the old. This is used while the change is being tested, allowing easy roll-back to the old schema.
  • MIGRATION_WRITE_NEW: Write only the new schema. Read the new schema preferentially, falling back to the old. This is used while running the maintenance script to migrate existing entries in the old schema to the new schema.
  • MIGRATION_NEW: Only read and write the new schema. The old schema (and the feature flag) may now be removed.
const MW_DATE_DEFAULT 'default'

Date format selectors; used in user preference storage and by Language::date() and co.

const MW_SUPPORTS_PARSERFIRSTCALLINIT 1

Hook support constants

const NS_IMAGE NS_FILE

NS_IMAGE and NS_IMAGE_TALK are the pre-v1.14 names for NS_FILE and NS_FILE_TALK respectively, and are kept for compatibility.

When writing code that should be compatible with older MediaWiki versions, either stick to the old names or define the new constants yourself, if they're not defined already.

Deprecated:
since 1.14
const NS_IMAGE_TALK NS_FILE_TALK
Deprecated:
since 1.14
const NS_MAIN 0

Real namespaces

Number 100 and beyond are reserved for custom namespaces; DO NOT assign standard namespaces at 100 or beyond. DO NOT Change integer values as they are most probably hardcoded everywhere see bug #696 which talked about that.

const NS_MEDIA -2

Virtual namespaces; don't appear in the page database

const OT_HTML 1

Allowed values for Parser::$mOutputType Parameter to Parser::startExternalParse(). Use of Parser consts is preferred:

  • Parser::OT_HTML
  • Parser::OT_WIKI
  • Parser::OT_PREPROCESS
  • Parser::OT_MSG
  • Parser::OT_PLAIN
const PROTO_HTTP 'http://'

Protocol constants for wfExpandUrl()

const RC_EDIT 0

RecentChange type identifiers

const SFH_NO_HASH 1

Flags for Parser::setFunctionHook Use of Parser consts is preferred:

  • Parser::SFH_NO_HASH
  • Parser::SFH_OBJECT_ARGS
const SHELL_MAX_ARG_STRLEN '100000'

Max string length for shell invocations; based on binfmts.h