Undefined variable: HTTP_RAW_POST_DATA

前端 未结 2 1417
既然无缘
既然无缘 2021-02-05 12:49

when I do a simple echo of $HTTP_RAW_POST_DATA i get the error:

Undefined variable: HTTP_RAW_POST_DATA

I read that in php.ini i need to un-tic

2条回答
  •  一生所求
    2021-02-05 13:22

    If you get

    Notice: Undefined variable: HTTP_RAW_POST_DATA

    Please open your Server file add find

    $server->service($HTTP_RAW_POST_DATA);
    

    and replace with following 2 lines.

    if ( !isset( $HTTP_RAW_POST_DATA ) ) $HTTP_RAW_POST_DATA =file_get_contents( 'php://input' );
    $server->service($HTTP_RAW_POST_DATA);
    

    I hope this would help.

提交回复
热议问题