mimetype = mimetype.toLowerCase();\r
if (mimetype.startsWith("application/pdf"))\r
return shared ? images.pdfShared() : images.pdf();\r
- else if (mimetype.startsWith("application/vnd.ms-excel"))\r
+ else if (mimetype.endsWith("excel"))\r
return shared ? images.spreadsheetShared() : images.spreadsheet();\r
- else if (mimetype.startsWith("application/msword"))\r
+ else if (mimetype.endsWith("msword"))\r
return shared ? images.wordprocessorShared() : images.wordprocessor();\r
- else if (mimetype.startsWith("application/vnd.ms-powerpoint"))\r
+ else if (mimetype.endsWith("powerpoint"))\r
return shared ? images.presentationShared() : images.presentation();\r
else if (mimetype.startsWith("application/zip") ||\r
mimetype.startsWith("application/gzip") ||\r
type = "text";
else if (mime.equals("text/html"))
type = "html";
- else if (mime.equals("application/msword"))
+ else if (mime.endsWith("msword"))
type = "doc";
- else if (mime.equals("application/vnd.ms-excel"))
+ else if (mime.endsWith("ms-excel"))
type = "xls";
- else if (mime.equals("application/vnd.ms-powerpoint"))
+ else if (mime.endsWith("powerpoint"))
type = "ppt";
else
nofile = true;