XLSM Extension mis-recognized
-
Just noticed that you’veadded .xlsm as an allowed upload mime. But wp_check_filetype_and_ext() is not recognizing it correctly and kicking it out.
Problem is in the comparison of $real_mime with the finfo_file() mime type returned by PHP. Tried in both PHP 5.6 and 7.2
PHP: XLSM => application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
WP: XLSM => application/vnd.ms-excel.sheet.macroEnabled.12With the mismatch it blanks the result giving a Security error for the upload.
According to official Apache list at:https://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/docs/conf/mime.types?view=annotate
WP has it right and PHP has it wrong, but the problem remains.
The page I need help with: [log in to see the link]
- The topic ‘XLSM Extension mis-recognized’ is closed to new replies.