用于特定于我的程序的二进制文件的哪种MIME类型? [英] Which MIME type to use for a binary file that's specific to my program?
问题描述
我的程序使用自己的二进制文件类型,所以我假设我不能使用MIME类型的text/plain,因为它不是7位ASCII文件.
My program uses its own binary file type, so I assume I can't use MIME type text/plain, as it is not a 7-bit ASCII file.
我应该将其命名为"application/myappname"吗?
Should I just call it "application/myappname"?
推荐答案
我建议application/octet-stream
作为 RFC2046 说:八位字节流"子类型用于表示主体包含任意二进制数据"和对于接收应用程序/八位字节流"实体的实现的建议操作是简单地提出:文件中的数据[...]".
I'd recommend application/octet-stream
as RFC2046 says "The "octet-stream" subtype is used to indicate that a body contains arbitrary binary data" and "The recommended action for an implementation that receives an "application/octet-stream" entity is to simply offer to put the data in a file[...]".
我认为这样一来,您将可以从任意程序中更好地处理代码,这在遇到未知的mime类型时可能会变得毫无用处.
I think that way you will get better handling from arbitrary programs, that might barf when encountering your unknown mime type.
这篇关于用于特定于我的程序的二进制文件的哪种MIME类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!