上传图片时,我可以信任来自 $_FILES
的文件类型吗?还是我必须再次检查 exif_imagetype()
?
最佳答案
来自documentation :
The mime type of the file, if the browser provided this information. An example would be "image/gif". This mime type is however not checked on the PHP side and therefore don't take its value for granted.
关于php - 我可以信任 $_FILES 的文件类型吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7308723/