今天在学习微信公众号的时候,在申请access_token 的时候出了一个问题
他报错说什么appID无效。查了很多资料都没用
结果在后面学习ES6的时候才发现
原来是我的请求写错了
const url='https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=${appID}&secret=${appsecret}'正确写法
const url=`https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=${appID}&secret=${appsecret}`
吃够了没文化的苦