{"action":"created","issue":{"url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/288","repository_url":"https://api.github.com/repos/NanoHttpd/nanohttpd","labels_url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/288/labels{/name}","comments_url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/288/comments","events_url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/288/events","html_url":"https://github.com/NanoHttpd/nanohttpd/issues/288","id":138705429,"number":288,"title":"Post parameters are empty for Content-Type: application/x-www-form-urlencoded","user":{"login":"lordspace","id":137558,"avatar_url":"https://avatars.githubusercontent.com/u/137558?v=3","gravatar_id":"","url":"https://api.github.com/users/lordspace","html_url":"https://github.com/lordspace","followers_url":"https://api.github.com/users/lordspace/followers","following_url":"https://api.github.com/users/lordspace/following{/other_user}","gists_url":"https://api.github.com/users/lordspace/gists{/gist_id}","starred_url":"https://api.github.com/users/lordspace/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lordspace/subscriptions","organizations_url":"https://api.github.com/users/lordspace/orgs","repos_url":"https://api.github.com/users/lordspace/repos","events_url":"https://api.github.com/users/lordspace/events{/privacy}","received_events_url":"https://api.github.com/users/lordspace/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/NanoHttpd/nanohttpd/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-03-05T18:16:29Z","updated_at":"2016-03-13T11:03:55Z","closed_at":null,"body":"I am using the server in an android app. I am making calls from php and from Java code and the post params are still empty. This really a crucial thing.\r\n\r\nI've tried this: http://stackoverflow.com/questions/22349772/retrieve-http-body-in-nanohttpd\r\nand it didn't work.\r\n\r\nGET request won't work for me because the data will become larger than 4K at some point.\r\n\r\n```\r\n<?php\r\n\r\n$url = 'http://localhost/echo/';\r\n\r\n$req_params = array(\r\n\t'cmd' => 'ping',\r\n    'data' => array(\r\n        'test' => 1,\r\n    ),\r\n);\r\n\r\n$ch = curl_init();\r\n\r\n//$dataEncoded = is_string($jsonData) ? $jsonData : json_encode($jsonData);\r\n$get = 0;\r\n\r\n$final_url = $url;\r\n\r\nif ( $get ) {    \r\n    $final_url .= '?' . http_build_query( $req_params );\r\n} else {\r\n    curl_setopt($ch, CURLOPT_POSTFIELDS, $req_params);\r\n    //curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query( $req_params ) );\r\n    curl_setopt($ch, CURLOPT_POST, 1);\r\n    //curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));\r\n}\r\n\r\ncurl_setopt($ch, CURLOPT_URL, $final_url);\r\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r\n\r\n$result = curl_exec($ch);\r\n\r\nvar_dump( $result );\r\n\r\ncurl_close($ch);\r\n"},"comment":{"url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/comments/195935779","html_url":"https://github.com/NanoHttpd/nanohttpd/issues/288#issuecomment-195935779","issue_url":"https://api.github.com/repos/NanoHttpd/nanohttpd/issues/288","id":195935779,"user":{"login":"roloreaper","id":296287,"avatar_url":"https://avatars.githubusercontent.com/u/296287?v=3","gravatar_id":"","url":"https://api.github.com/users/roloreaper","html_url":"https://github.com/roloreaper","followers_url":"https://api.github.com/users/roloreaper/followers","following_url":"https://api.github.com/users/roloreaper/following{/other_user}","gists_url":"https://api.github.com/users/roloreaper/gists{/gist_id}","starred_url":"https://api.github.com/users/roloreaper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/roloreaper/subscriptions","organizations_url":"https://api.github.com/users/roloreaper/orgs","repos_url":"https://api.github.com/users/roloreaper/repos","events_url":"https://api.github.com/users/roloreaper/events{/privacy}","received_events_url":"https://api.github.com/users/roloreaper/received_events","type":"User","site_admin":false},"created_at":"2016-03-13T11:03:55Z","updated_at":"2016-03-13T11:03:55Z","body":"@lordspace \r\nAre you sure the contentType is correct. I did a code walk through on the parseBody method \r\nit check for multipart and if not then parses the payload if the contentType header is correct. Just verify that in the debug"}}