|MediaWiki file: index.php|
|Source code:||master • 1.32.1 • 1.31.1|
|Classes:||Find code • Find documentation|
Most requests result in the following actions in
- First, it includes WebStart.php, which includes LocalSettings.php and Setup.php.
- Next it instantiates a MediaWiki object called $mediaWiki which is defined in MediaWiki.php.
- It then checks the maxlag parameter, which may cause the request to be rejected.
- It calls the function
MediaWiki::checkInitialQueries()in MediaWiki.php, which creates a Title object depending of the title and action parameters from the URL.
- If ajax is enabled and the
actionparameter is set to
ajax, then an object will be created to handle that request and the script will stop after that.
- Otherwise some globals are stored in $mediaWiki to be used in the next steps.
- It calls
MediaWiki::initialize()which does most of the work of the request.
MediaWiki::finalCleanup()is called. That function does the deferred updates, runs jobs from the queue depending on $wgJobRunRate and outputs the HTML by calling
MediaWiki::restInPeace()is called to log profiling data.
Version 1.18 and higherEdit
|MediaWiki version:||≥ 1.18|
As of MediaWiki version 1.18, some of the startup logic has been moved from index.php, and index.php performs the following actions: