Manual:$wgCrossSiteAJAXdomains
From MediaWiki.org
| API: $wgCrossSiteAJAXdomains | |
|---|---|
| Controls which domains may make cross-site AJAX requests to the MediaWiki API. |
|
| Introduced in version: | 1.16.0 (r54127) |
| Removed in version: | still in use |
| Allowed values: | array or '*' |
| Default value: | array() |
Other settings: Alphabetical | By Function
[edit] Details
Allows AJAX requests from certain domains to make cross-site requests to a wiki's API. This uses the Access-Control-Allow-Origin HTTP header. Note that this is only supported by newer browsers (FF 3.5 and IE8 as of August 2009). This only affects requests to the API. Other entry points (index.php) are not affected.
This variable can be set in 3 ways.
It can be used to allow any domain to access the API via AJAX:
$wgCrossSiteAJAXdomains = '*';
It can be set to an array of domains to allow:
$wgCrossSiteAJAXdomains = array( 'http://en.wikipedia.org', 'http://en.wikibooks.org' );
By default the variable is set to an empty array (no access allowed).
| Language: | English • Français |
|---|