获得过 0 次赞
回答过的问题获得 0 次赞
分享过的文章/案例获得 0 次赞
评论与回复获得 0 次赞
[图片]
调用图片验证接口失败?api.weixin.qq.com/wxa/img_sec_check 接口调用后,一直接提示: media data missing rid: 5ff815d8-41728925-6fb91bd0" 图片参数没有接收到 $res = self::post($url, ['media' => $_FILES['image']]); $headers = ['Content-Type:application/json']; $ch = curl_init(); curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); // 关键点 curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data, JSON_UNESCAPED_UNICODE)); // 【* 关键点】 $res = curl_exec($ch); curl_close($ch);
2021-01-08