Titanium + Rails +回形针=== NULL值? [英] Titanium + Rails + Paperclip === NULL values?

查看:146
本文介绍了Titanium + Rails +回形针=== NULL值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

编辑:真正的问题是,您是否可以使用JSON http标头,以及如何格式化文件的XHR发送到Rails应用程序.

The real question was whether or not you can use a JSON http header, and how to format an XHR send of a file to a Rails application.

推荐答案

为了成功将文件保存到那里,您可能需要组合一个内容类型为"multipart/form-data"的请求.我发现以下页面似乎具有正确的信息,可以正确地向您发送信息:

In order to get the file there successfully, you might need to assemble a request with a content-type of "multipart/form-data". Here's a page I found that seems to have the right kind of information to send you in the right direction:

http://www.smokycogs.com/blog/titanium-tutorial-how-to-up-up-file-to-a-server/

这篇关于Titanium + Rails +回形针=== NULL值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆