I would like upload .docx, but
In $_FILES['field']['type']
is application/vnd.openxmlformats-officedocument.wordprocessingml.document
, but in mime_content_type()
return application/zip
Why these types are diffrent? Which is good?
The DOCX format consists of a number of different files all wrapped up in a zip file. The software you are using is examining the file, seeing it is a zip file and reporting it with the standard MIME type for zip.
"Good" is somewhat subjecting, but application/vnd.openxmlformats-officedocument.wordprocessingml.document
is probably better as it is more specific.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.