开发者

How to get raw request in PHP?

开发者 https://www.devze.com 2023-01-08 05:47 出处:网络
I have a script called api.php on my server. I call it from other server using POST request. Is there any way to get in my api.php raw contents of POST re开发者_开发百科quest?use the following code

I have a script called api.php on my server. I call it from other server using POST request. Is there any way to get in my api.php raw contents of POST re开发者_开发百科quest?


use the following code

$data = file_get_contents('php://input');
0

精彩评论

暂无评论...
验证码 换一张
取 消