在百度地图IP静态图API中,例子是这样的:
http://api.map.baidu.com/staticimage/v2?ak=E4805d16520de693a3fe707cdc962045&mcode=666666¢er=116.403874,39.914888&width=300&height=200&zoom=11
//请将AK替换为您的AK
还没申请ssl证书前还行,但申请后,域名开头变成了https,则不行了。
由于用https协议去访问http是违规的。所以报错。在链接处将http改成https即可。
https://api.map.baidu.com/staticimage/v2?ak=E4805d16520de693a3fe707cdc962045&mcode=666666¢er=116.403874,39.914888&width=300&height=200&zoom=11