13.01.2019
Posted by 

A MIME attachment with the content type 'application/octet-stream' is a binary file. Typically, it will be an application or a document that must be opened. The official MIME type for JSON text is 'application/json', and most modern implementations have adopted this. The (unofficial) MIME type 'text/json' or the content-type 'text/javascript' also get legacy support. I am using version 1.6.8 and was able to upload images in the past as they are all in my mime type file. Why all of a sudden I am unable to do.

Steps to reproduce the issue Go to: Content / Media Click green Upload button, upload PDF file Expected result PDF file uploads without issue Actual result Error Invalid mime type detected. System information (as much as possible) Site hosted at Rochen Database Version 10.1.23-MariaDB PHP Version 7.0.19 Web Server LiteSpeed WebServer to PHP Interface litespeed Joomla! Version Joomla!

3.7.2 Stable [ Amani ] 22-May-2017 09:46 GMT Joomla! Platform Version Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT I have disabled 'check mime types' in the Media Options (click Options button from Media screen). Legal MIME types: image/jpeg,image/gif,image/png,image/bmp,application/x-shockwave-flash,application/msword,application/excel,application/pdf,application/powerpoint,text/plain,application/x-zip Legal extensions: bmp,csv,doc,gif,ico,jpg,jpeg,odg,odp,ods,odt,pdf,png,ppt,swf,txt,xcf,xls,BMP,CSV,DOC,GIF,ICO,JPG,JPEG,ODG,ODP,ODS,ODT,PDF,PNG,PPT,SWF,TXT,XCF,XLS Additional comments I have been uploading files through the Media Manager. JPG and PNG work, while PDF does not. I reported this to Rochen, who confirmed that finfo_open and mime_content_type were installed, available, and working correctly.

What Does Invalid Mime Type Mean

Invalid

What Does Invalid Mime Type Mean Mean

Their response was this: 'Well there seems to be compatibility issue with mime_content_type on Joomla version and PHP v7.0, If I switch the PHP version to v5.6 it is working fine. It appears the patch provided isn't working on 3.7.1 and 3.7.2, due to mime_content_type. Previously I was running PHP 7.0.19. Confirmed issue on Rochen server: PHP Built On Linux impress51.directrouter.com 3.10.0-427.36.1.lve1.4.43.el7.x86_64 SMP Wed Mar 29 16:13:25 EDT 2017 x86_64 Database Version 10.1.23-MariaDB Database Collation utf8_general_ci Database Connection Collation utf8mb4_general_ci PHP Version 7.0.18 Web Server Apache WebServer to PHP Interface cgi-fcgi Joomla! Version Joomla! 3.7.2 Stable [ Amani ] 22-May-2017 09:46 GMT Joomla! Platform Version Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT User Agent Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0.

Update from Rochen -- After telling me that fileinfo and mime_content_type were enabled, they were able to get the PDF upload working under PHP 5.6. (In the control panel, go to PHP version and switch it.) However, a second support person has come back to me after that change was made. He switched PHP 5.6 back to PHP 7.0. The PDF upload now works. He says 'I suppose it's possible that a needed PHP extension (like fileinfo) hadn't been selected previously, but the new defaults in the selector resolved the problem.' So, suggestion for other Rochen people with this issue: a. Log into cPanel b. Activator for office 2010.

Choose 'select PHP version' under 'software' heading c. See if fileinfo is checked. If it IS checked, and you can't upload PDFs, then try: a. Switch the version to 5.6 with the dropdown and apply the setting b. Now switch back to PHP 7.0.

Test to see if you can upload PDFs now. My guess is that 'fileinfo' is showing as checked when it's not really set. I am sorry but I cannot replicate this on our servers (PHP 7.1.14). Neither in default media manager nor in /TinyMCEJCE.

Invalid Mime Content Outlook Mac

I am sorry but I cannot replicate this on our servers (PHP 7.1.14). Sure the most of us can't as it looks like a server / hosting issue. So by using the media manager upload they show but when upload with any editor they don't show in the media manager in admin backend despite being listed in the file system (FTP) Please double check that. For the frontend image button this is expected (only images) and this is a longstanding behavior so nothing changed in 3.7.1/2 In the backend it is working fine for me.