如何从PHP中读取Stackoverflow API的响应?回复是GZIP-ed.我发现了以下建议:
$url = "http://api.stackoverflow.com/1.1/questions/" . $question_id;
$data = file_get_contents($url);
$data = http_inflate($data);
Run Code Online (Sandbox Code Playgroud)
但该功能http_inflate()在我正在使用的安装上不可用.
还有其他一些简单的方法来实现它吗?