diff options
author | Cash Costello <cash.costello@gmail.com> | 2012-06-16 22:05:07 -0400 |
---|---|---|
committer | Cash Costello <cash.costello@gmail.com> | 2012-06-16 22:05:07 -0400 |
commit | 3f42ca11e752696d9aaafe9b006d8e0f07136928 (patch) | |
tree | 01cf3b9b767020bb1b894c1ada684e19cab5c3a7 /mod/file/start.php | |
parent | ab2072983b4f35c0495f920409f0f5bf5c75ee27 (diff) | |
download | elgg-3f42ca11e752696d9aaafe9b006d8e0f07136928.tar.gz elgg-3f42ca11e752696d9aaafe9b006d8e0f07136928.tar.bz2 |
Fixes #4079 detecting docx, xlsx, and pptx files in file plugin
Diffstat (limited to 'mod/file/start.php')
-rw-r--r-- | mod/file/start.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/mod/file/start.php b/mod/file/start.php index 120129276..172042332 100644 --- a/mod/file/start.php +++ b/mod/file/start.php @@ -240,11 +240,15 @@ function file_get_simple_type($mimetype) { switch ($mimetype) { case "application/msword": + case "application/vnd.openxmlformats-officedocument.wordprocessingml.document": return "document"; break; case "application/pdf": return "document"; break; + case "application/ogg": + return "audio"; + break; } if (substr_count($mimetype, 'text/')) { @@ -357,11 +361,15 @@ function file_icon_url_override($hook, $type, $returnvalue, $params) { $mapping = array( 'application/excel' => 'excel', 'application/msword' => 'word', + 'application/ogg' => 'music', 'application/pdf' => 'pdf', 'application/powerpoint' => 'ppt', 'application/vnd.ms-excel' => 'excel', 'application/vnd.ms-powerpoint' => 'ppt', 'application/vnd.oasis.opendocument.text' => 'openoffice', + 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' => 'word', + 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' => 'excel', + 'application/vnd.openxmlformats-officedocument.presentationml.presentation' => 'ppt', 'application/x-gzip' => 'archive', 'application/x-rar-compressed' => 'archive', 'application/x-stuffit' => 'archive', |