iphone - 二进制 plist 的 HTTP 内容类型是什么?

标签 iphone ruby-on-rails plist mime-types

我正在修改 Rails 服务器以通过 POST 和 PUT 请求处理来自 iPhone 客户端的二进制 plist。据我所知,文本 plist 的内容类型是 text/plist。我希望服务器能够处理文本和二进制 plist,所以我想区分这两种形式。二进制 plist 的内容类型是什么?

最佳答案

我相信大多数二进制格式前面都是application,所以可能是application/plist

参见 RFC1341 的底部.

更新

就像 Pumbaa80 提到的那样,由于 application/plist 不是标准 mime 类型,因此应该是 application/x-plist

在 RFC2045 中对此进行了解释:

In the future, more top-level types may be defined only by a standards-track extension to this standard. If another top-level type is to be used for any reason, it must be given a name starting with "X-" to indicate its non-standard status and to avoid a potential conflict with a future official name.

关于iphone - 二进制 plist 的 HTTP 内容类型是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3603851/

相关文章:

ruby-on-rails - 添加用户 :name to devise invitable edit. html.erb 表单

ruby-on-rails - 如何从 Rails 模板(ERB 文件)中的错误中拯救出来

ios - xcode info.plist 构建变量 ${PRODUCT_NAME :rfc1034identifier} seems completely undocumented?

iphone - NSDate 倒计时天数小时分钟数的问题

ios - 如何在其 ViewController 的 viewDidAppear 之前确定 UIView 大小

iphone - iOS 7 导航栏文本和箭头颜色

ios - 如何从我的 iPhone 应用程序的 config.xml 文件中的 info.plist 中读取键的值

iphone - 针对 iphone 4s 和 5/5c/5s 屏幕尺寸进行开发的最佳实践

ruby-on-rails - Ubuntu 17 上的 Ruby 构建失败错误

ios - 通过 UIButton 将数据传递到另一个 Controller 上的 UITableView