From the link in the config file:
If set to TRUE
, PHP will always populate the $HTTP_RAW_POST_DATA
containing the raw POST data. Otherwise, the variable is populated only when the MIME type of the data is unrecognised.
The preferred method for accessing raw POST data is php://input
, and $HTTP_RAW_POST_DATA
is deprecated in PHP 5.6.0 onwards. Setting always_populate_raw_post_data to -1 will opt into the new behaviour that will be implemented in a future version of PHP, in which $HTTP_RAW_POST_DATA
is never defined.
Regardless of the setting, $HTTP_RAW_POST_DATA
is not available with enctype="multipart/form-data".
As per the documentation setting it to -1, rather than TRUE
uses the PHP 7.0 version which doesn't even define $HTTP_RAW_POST_DATA
.
Anyway, as also mentioned in the documentation, you really should just be using file_get_contents("php://input");
to read the raw POST data.