1
huijiewei 2015-01-29 22:11:30 +08:00
查 Content-Type 了没?
|
2
cevincheung 2015-01-29 22:13:09 +08:00 1
echo file_get_contents('php://input');
试试呢 |
3
huijiewei 2015-01-29 22:19:23 +08:00 1
补充说明下,POST 就是 POST ,不要用 PUT
|
4
q84629462 OP @huijiewei
//AsynchttpClient读取到的$_SERVER ["CONTENT_TYPE"]=> string(33) "application/x-www-form-urlencoded" ["HTTP_CONTENT_TYPE"]=> string(33) "application/x-www-form-urlencoded" ["HTTP_USER_AGENT"]=> string(62) "android-async-http/1.4.4 (http://loopj.com/android-async-http)" //随便写一个html form提交的$_SERVER ["CONTENT_TYPE"]=> string(33) "application/x-www-form-urlencoded" ["HTTP_CONTENT_TYPE"]=> string(33) "application/x-www-form-urlencoded" ["HTTP_USER_AGENT"]=> string(120) "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.93 Safari/537.36" 目测这里没有问题 @cevincheung 使用echo file_get_contents('php://input');可以看到参数诶,但var_dump($_POST);依然是array(0) {} 这是什么问题? |