https://bugzilla.wikimedia.org/show_bug.cgi?id=38432
Web browser: ---
Bug #: 38432
Summary: Uploading MS Word files doesn't work ("File extension
does not match the detected MIME type of the file")
Product: MediaWiki
Version: 1.19
Platform: PC
OS/Version: Windows Server 2008
Status: NEW
Severity: normal
Priority: Unprioritized
Component: Uploading
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Classification: Unclassified
Mobile Platform: ---
Uploading a .doc file to MW 1.19.1 (which, incidentally, isn't listed in the
versions box here), I get the following error:
File extension ".doc" does not match the detected MIME type of the file
(application/zip).
I tried removing "doc" from application/msword in /includes/mime.types and then
also adding it to application/zip (recommended at [1]). The former edit did
nothing; the latter resulted in:
The file is a corrupt or otherwise unreadable ZIP file. It cannot be
properly checked for security.
I tried keeping the above modifications to /includes/mime.types and adding
$wgAllowJavaUploads = true; to LocalSettings.php, as recommended at [2], and
uploading of these files works correctly.
However, this seems pretty hacky. Surely allowing .doc files in
$wgFileExtensions should be enough, and they shouldn't be treated as zip files
or jars or anything?
--
[1]
http://www.mediawiki.org/wiki/Manual_talk:Mime_type_detection#Fix_for_Uploading_MS_Word_2007_.28and_greater.29_Files
[2]
http://www.mediawiki.org/wiki/Thread:Talk:MediaWiki_1.18/file_upload_error/reply
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l