Hi i have the following problem
i have a script that needs to read data from the HTTP request body. to retrieve data using HTTP PUT and i am using the following code
$body = @file_get_contents('php://input');
if i check $_SERVER['Content-Type'] indeed contains the length of the HTTP body but file_get_contents function returns an empty string if i change from PUT to POST everything works OK.
my best thinking is
1 - i am missing a heading in the HTTP request i am sending the following headers.
Host: local.gle.com/
Content-type: application/x-www-form-urlencoded
Content-Length: 451
Authorization: auth asdfiuyuwiinbvbsksoaklsjdkfioieio
2 - I need to set some parameter in php.ini or httpd.conf
i am using
Apache 2.2
PHP 5.2
Zend Framework 1.7