diff --git a/inc/inc.Utils.php b/inc/inc.Utils.php index dac901ce3..9d7d8f736 100644 --- a/inc/inc.Utils.php +++ b/inc/inc.Utils.php @@ -609,6 +609,7 @@ function get_extension($mimetype) { /* {{{ */ if(empty($mimetype)) return false; switch($mimetype) { case 'image/bmp': return '.bmp'; + case 'image/x-ms-bmp': return '.bmp'; case 'image/cis-cod': return '.cod'; case 'image/gif': return '.gif'; case 'image/ief': return '.ief'; @@ -630,14 +631,28 @@ function get_extension($mimetype) { /* {{{ */ case 'image/x-jps': return '.jps'; case 'image/x-freehand': return '.fh'; case 'image/svg+xml': return '.svg'; + case 'audio/mp3': return '.mp3'; + case 'audio/mpeg': return '.mpeg'; + case 'audio/ogg': return '.ogg'; + case 'video/mp4': return '.mp4'; + case 'video/webm': return '.webm'; case 'application/zip': return '.zip'; + case 'application/x-gzip': return '.gz'; case 'application/x-rar': return '.rar'; + case 'application/x-compressed-tar': return '.tgz'; case 'application/pdf': return '.pdf'; + case 'application/dxf': return '.dxf'; + case 'application/msword': return '.doc'; case 'application/postscript': return '.ps'; case 'application/vnd.openxmlformats-officedocument.wordprocessingml.document': return '.docx'; case 'application/vnd.openxmlformats-officedocument.presentationml.presentation': return '.pptx'; case 'text/plain': return '.txt'; case 'text/csv': return '.csv'; + case 'text/rtf': return '.rtf'; + case 'text/xml': return '.xml'; + case 'text/x-php': return '.php'; + case 'text/x-tex': return '.tex'; + case 'message/rfc822': return '.eml'; default: return false; } } /* }}} */