该功能如何exact($args)
运作?
是什么意思$before_widget
,$after_widget
?
我试图通过curl连接从URL获取JSON数据.当我打开链接时:它显示{"version":"N/A","success":true,"status":true}.
现在,我希望获得以上内容.
到目前为止我使用了这个:
$loginUrl = 'http://update.protect-website.com/index.php?plugin=firewall&action=getVersion';
$ch = curl_init();
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_URL,$loginUrl);
$result=curl_exec($ch);
curl_close($ch);
var_dump(json_decode($result));
Run Code Online (Sandbox Code Playgroud)
但是,我总是得到NULL,有人知道哪里出错了吗?