Re: fileinfo returning wrong mime type for Excel files
| From: | Christoph Boget | Date: | Thu, 30 Jul 2009 13:46:32 +0000 |
| Subject: | Re: fileinfo returning wrong mime type for Excel files | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-296058@lists.php.net to get a copy of this message | ||
> Have you tried using 'file -i' from the command line: after all you are looking
> for a MIME type with your fileinfo...
> Having said that, with file -i on my system, Word documents are
> 'application/msword' and Excel files are 'application/octet-stream'
$ file -i excel.xls
excel.xls: application/msword
The xls file I am using was generated with Excel (of Office 2007) for
the Mac. So either you have a different magic file (assuming that's
what the file command uses) than I do or different versions of excel
contain different information.
thnx,
Christoph