abstract:<?php$method = "GET";// 请求示例 url 默认请求参数已经做URL编码$url = "http://api01.bitspaceman.com:8000/share/weibo?apikey={您自己的apikey}&";$curl = curl_init(); curl_setopt($curl, CURLOPT_CU
<?php$method = "GET";// 请求示例 url 默认请求参数已经做URL编码$url = "http://api01.bitspaceman.com:8000/share/weibo?apikey={您自己的apikey}&";$curl = curl_init(); curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method); curl_setopt($curl, CURLOPT_URL, $url); curl_setopt($curl, CURLOPT_FAILONERROR, false); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_HEADER, true); curl_setopt($curl, CURLOPT_ENCODING, "gzip"); var_dump(curl_exec($curl)); ?>
Correcting teacher:天蓬老师Correction time:2019-03-30 10:33:54
Teacher's summary:你这个代码, 你自己过上一周, 是否还能看明白呢? 所有代码写在一行, 是考验哪个呢?
作业既然写了, 就好好写, 不要应付