Merge pull request #351 from PrestaEdit/patch-23

[*] WS: POST for php://input and XML ressource
This commit is contained in:
Gregory Roussac committed 2013-07-24 03:08:23 -07:00
commit cfa6e61acb
1 file changed
+3 -3
+3 -3
View File
@@ -66,8 +66,8 @@ else
// if no XML // if no XML
$input_xml = NULL; $input_xml = NULL;
// if a XML is in PUT // if a XML is in PUT or in POST
if ($_SERVER['REQUEST_METHOD'] == 'PUT') if (($_SERVER['REQUEST_METHOD'] == 'PUT') || ($_SERVER['REQUEST_METHOD'] == 'POST'))
{ {
$putresource = fopen("php://input", "r"); $putresource = fopen("php://input", "r");
while ($putData = fread($putresource, 1024)) while ($putData = fread($putresource, 1024))
@@ -113,4 +113,4 @@ if (isset($result['type']))
} }
} }
ob_end_flush(); ob_end_flush();