How to remove obsolete warning message for $ HTTP_RAW_POST_DATA?

2

We are using php://input in requests in AngularJS :

//método
public function putData() {
     $params = file_get_contents("php://input");
     return json_decode($params);
}

How it's being used:

$postData = $this->putData();
$request = $this->getRequest();
$request->setParam('data',$postData->token);

I've tried:

$GLOBALS['HTTP_RAW_POST_DATA'] = -1;

Also in htaccess:

<IfModule mod_php5.c>
    php_flag always_populate_raw_post_data -1
</IfModule>

And in php.ini:

always_populate_raw_post_data = -1

And none worked. I'm using Zendframework 1.12.20

In order to see the errors, we are using php-console , which accuses several warnings of this type.

    
asked by anonymous 14.02.2017 / 13:30

0 answers