【发布时间】:2014-05-19 21:18:23
【问题描述】:
我正在尝试使用以下方式发送带有一些 json 数据的发布请求:
curl --verbose -X POST -d @testfile.json http://oururl.com/someapi --header "Content-Type:application/json"
另一端的视图显示request.POST.dict() -- 但request.POST 显示为空(尽管内容长度已设置)!我以前用过这种方法,从来没有出现过这种情况,不知道是怎么回事。
【问题讨论】: