(Created page with "{{Textbox|boxtype=important|header=XML file type:{{Bsvs|bsvFrom=4.x+}}|text=The ''xml'' file type is blacklisted since MW 1.39 and has to be allowed in ''LocalSettings.php'': <pre> $GLOBALS['wgProhibitedFileExtensions'] = array_diff( $GLOBALS['wgProhibitedFileExtensions'] ?? [], [ 'xml' ] ); $GLOBALS['wgMimeTypeExclusions'] = array_diff( $GLOBALS['wgMimeTypeExclusions'] ?? [], [ 'application/xml', 'text/xml' ] ); </pre>|icon=no}}") Tag: 2017 source edit |
No edit summary Tag: 2017 source edit |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
{{Textbox|boxtype=important|header=XML file type: | {{Textbox|boxtype=important|header=XML file type:|text=The ''xml'' file type is blacklisted since MW 1.39 and has to be allowed in ''LocalSettings.php'': | ||
< | <syntaxhighlight lang="php"> | ||
$GLOBALS['wgProhibitedFileExtensions'] = array_diff( $GLOBALS['wgProhibitedFileExtensions'] ?? [], [ 'xml' ] ); | $GLOBALS['wgProhibitedFileExtensions'] = array_diff( $GLOBALS['wgProhibitedFileExtensions'] ?? [], [ 'xml' ] ); | ||
$GLOBALS['wgMimeTypeExclusions'] = array_diff( $GLOBALS['wgMimeTypeExclusions'] ?? [], [ 'application/xml', 'text/xml' ] ); | $GLOBALS['wgMimeTypeExclusions'] = array_diff( $GLOBALS['wgMimeTypeExclusions'] ?? [], [ 'application/xml', 'text/xml' ] ); | ||
</ | </syntaxhighlight>|icon=no}} |
Latest revision as of 08:09, 1 August 2024
XML file type:The xml file type is blacklisted since MW 1.39 and has to be allowed in LocalSettings.php:
$GLOBALS['wgProhibitedFileExtensions'] = array_diff( $GLOBALS['wgProhibitedFileExtensions'] ?? [], [ 'xml' ] );
$GLOBALS['wgMimeTypeExclusions'] = array_diff( $GLOBALS['wgMimeTypeExclusions'] ?? [], [ 'application/xml', 'text/xml' ] );