MediaWiki REL1_37
load.php
Go to the documentation of this file.
1<?php
29
30// This endpoint is supposed to be independent of request cookies and other
31// details of the session. Enforce this constraint with respect to session use.
32define( 'MW_NO_SESSION', 1 );
33
34define( 'MW_ENTRY_POINT', 'load' );
35
36require __DIR__ . '/includes/WebStart.php';
37
39
40function wfLoadMain() {
41 global $wgRequest;
42
43 // Disable ChronologyProtector so that we don't wait for unrelated MediaWiki
44 // writes when getting database connections for ResourceLoader. (T192611)
45 MediaWikiServices::getInstance()->getDBLoadBalancerFactory()->disableChronologyProtection();
46
47 $resourceLoader = MediaWikiServices::getInstance()->getResourceLoader();
48 $context = new ResourceLoaderContext( $resourceLoader, $wgRequest );
49
50 // Respond to ResourceLoader request
51 $resourceLoader->respond( $context );
52
53 // Append any visible profiling data in a manner appropriate for the Content-Type
54 Profiler::instance()->setAllowOutput();
55 Profiler::instance()->logDataPageOutputOnly();
56
57 $mediawiki = new MediaWiki();
58 $mediawiki->doPostOutputShutdown();
59}
$wgRequest
Definition Setup.php:702
MediaWikiServices is the service locator for the application scope of MediaWiki.
Context object that contains information about the state of a specific ResourceLoader web request.
$mediawiki
Definition img_auth.php:48
wfLoadMain()
Definition load.php:40
A helper class for throttling authentication attempts.