使用微信公众平台,公众号接口uploadImg上传图片,的时候,access_token明明是对的,appsecret也是对的,但是一直返回40001错误,获取access_token时AppSecret错误,或者access_token无效,,研究了很久
返回的如下:
Array
([url] => https://api.weixin.qq.com/cgi-bin/media/uploadimg?access_token=ZFvCd4NhwYMDgNp98opxPc_3b4oiSHJpsgtx8Z_Z4KM77zpxSRQCpCTFPREohBkIdomn_nF1kODoseVFyJemOoT156DZu39cmvk2zb93wzb5DF9OUPWEr3lc2yvdUCsRKOPjAAAYCD[content_type] => [http_code] => 0[header_size] => 0[request_size] => 0[filetime] => -1[ssl_verify_result] => 20[redirect_count] => 0[total_time] => 0.078[namelookup_time] => 0.015[connect_time] => 0.031[pretransfer_time] => 0[size_upload] => 0[size_download] => 0[speed_download] => 0[speed_upload] => 0[download_content_length] => -1[upload_content_length] => -1[starttransfer_time] => 0[redirect_time] => 0[certinfo] => Array()[redirect_url] =>
)
实际上,微信已经返回图片的URL了,,但是返回的http_code 是0,而不是200,,所以就一直报错了