문제

I've set up a MediaWiki page and now I'm trying to upload files beside images to it.
LocalSettings.php:

$wgEnableUploads = true;
$wgCheckFileExtensions = false;
$wgStrictFileExtensions = false;

I get this error: File extension ".vssettings" does not match the detected MIME type of the file (application/xml).
How can I upload this file anyway? I want users with admin rights to be able to upload any file type.

I found no solution in the documentation.

도움이 되었습니까?

해결책

You also need to set $wgVerifyMimeType to false, to bypass the mime type check. As noted in the docs, you do not want to do this on a public wiki.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top