Wrong mime-type?!
Moderator: General Moderators
Wrong mime-type?!
I've got a CMS under development, and to have the guy upload pictures, I'm having him upload a ZIP which the server then unzips. It was working a few weeks ago, but now when I upload the zip file, the $_FILES type is coming back as a application/octet-stream, instead of the application/x-zip-compressed I wanted. What's going on? I've tried rezipping, nothing. Why is it going up as a octet and not the zip it actually is?!
- AbraCadaver
- DevNet Master
- Posts: 2572
- Joined: Mon Feb 24, 2003 10:12 am
- Location: The Republic of Texas
- Contact:
Re: Wrong mime-type?!
The browser sends the file type and it isn't reliable. You can try either mime_content_type() or finfo_file().
mysql_function(): WARNING: This extension is deprecated as of PHP 5.5.0, and will be removed in the future. Instead, the MySQLi or PDO_MySQLextension should be used. See also MySQL: choosing an API guide and related FAQ for more information.
Re: Wrong mime-type?!
Nice. Thank you. I must have been testing in another browser before.