pwes24 Posted April 30, 2008 Share Posted April 30, 2008 Hello everyone, I have an upload script that uploads resumes to the server. I'd like to make sure that only ms word documents are uploaded. What is the mime type for the ms word .docx? I know the mime type for the other .doc is application/msword. Thank you. Link to comment https://forums.phpfreaks.com/topic/103639-mime-type/ Share on other sites More sharing options...
dooper3 Posted April 30, 2008 Share Posted April 30, 2008 Technically I believe docx files are zip files, so you can upload it restricting it to a zip mime type, and renaming it later back to docx if you need should still make it open fine as the docx type. Link to comment https://forums.phpfreaks.com/topic/103639-mime-type/#findComment-530705 Share on other sites More sharing options...
corbin Posted April 30, 2008 Share Posted April 30, 2008 Mime types are useless. I can tell my browser to tell you a .php file is a Word file, and at that point you have major problems. Webservers handle files based on file extensions, so you should do the same. (Check mime types too if you want, but.... Those, like all use input, aren't trust worthy.) Anyway, I googled around, and for the life of me can't find the mime type of .docx files.... Link to comment https://forums.phpfreaks.com/topic/103639-mime-type/#findComment-530712 Share on other sites More sharing options...
jonsjava Posted April 30, 2008 Share Posted April 30, 2008 docx is the new Word 2007 document format (their attempt at a new open standard) Link to comment https://forums.phpfreaks.com/topic/103639-mime-type/#findComment-530721 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.