Version: CI 3.1.0
Uploading EPS files via form, however, in some instances we receive the following error
Quote:Error:
The filetype you are attempting to upload is not allowed.
All EPS file mime-types have been declared in application/config/mimes.php. Have tried them both individually and as an array below.
Code:
'eps' => array('application/postscript', 'application/eps', 'application/x-eps', 'image/eps', 'image/x-eps'),
The issue appears to be some EPS files contain a first line beginning with
ÅÐÓÆ which seems to be and identifier that the EPS file containts a TIFF/WMF preview thumbnail. This line can mistakenly be interpreted as a Postscript command.
A standard EPS file begins immediately with the type identifier such as "%!PS-Adobe-3.1 EPSF-3.0" . Apparently code igniter can then not identify this file type properly and fails with the error. If we open the file in a text editor and remove the offending line, upload succeeds as expected.
Is there a generic mime-type I can use to force and upload without actually identifying the file or some other work around? We are receiving artwork from many sources and would be unable to inform them of a requirement for modifying their Adobe settings.