收藏
回答

阿里云CDN+OSS,图片上传OSS后,小程序环境下通过Image标签访问图片访问出现404错误?

生成的图片地址,小程序模拟器访问没有问题,pc浏览器也没问题。但是开发版环境和线上环境中,无法访问图片资源,显示404错误,有哪位大神遇到过?

模拟器访问响应消息头:

  1. Request Method: GET
  2. Status Code: 200 OK
  3. Remote Address: 60.217.246.219:443
  4. Referrer Policy: unsafe-url
  5. Response Headers
  6. Accept-Ranges: bytes
  7. Ali-Swift-Global-Savetime: 1666832845
  8. Connection: keep-alive
  9. Content-Length: 15173
  10. Content-MD5: 4FD9USsqbh98/OuJ9aYScg==
  11. Content-Type: image/jpeg
  12. Date: Thu, 27 Oct 2022 01:07:25 GMT
  13. EagleId: 3cd9f69616668328449463776e
  14. ETag: "E050FD512B2A6E1F7CFCEB89F5A61272"
  15. Last-Modified: Tue, 25 Oct 2022 05:49:02 GMT
  16. Server: Tengine
  17. Timing-Allow-Origin: *
  18. Via: cache30.l2cn1807[220,219,200-0,M], cache38.l2cn1807[221,0], kunlun10.cn2206[238,238,200-0,M], kunlun2.cn2206[240,0]
  19. X-Cache: MISS TCP_MISS dirn:-2:-2
  20. x-oss-cdn-auth: success
  21. x-oss-hash-crc64ecma: 16869370607212489153
  22. x-oss-object-type: Normal
  23. x-oss-request-id: 6359D9CD733AC83230F2A947
  24. x-oss-server-side-encryption: AES256
  25. x-oss-server-time: 52
  26. x-oss-storage-class: Standard
  27. X-Swift-CacheTime: 15552000
  28. X-Swift-SaveTime: Thu, 27 Oct 2022 01:07:25 GMT
  29. Request Headersview source
  30. Accept: image/avif,image/webp,image/apng,image/svg+xml,image/*,*/*;q=0.8
  31. Accept-Encoding: gzip, deflate, br
  32. Connection: keep-alive
  33. Host: res.newcards.cn
  34. Referer: https://servicewechat.com/wx19538ac9c64f8072/devtools/page-frame.html
  35. Sec-Fetch-Dest: image
  36. Sec-Fetch-Mode: no-cors
  37. Sec-Fetch-Site: cross-site
  38. User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 11_0 like Mac OS X) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Mobile/15A372 Safari/604.1 wechatdevtools/1.06.2210141 MicroMessenger/8.0.5 Language/zh_CN webview/23 desktopapp miniprogram port/18052 token/a2a47d51de557da8114167277332611a runtime/2
  39. Query String Parametersview source
  40. view URL encoded
  41. OSSAccessKeyId: LTAI5tNe3WjfkdDrTmmgDLKr
  42. Expires: 1666836444
  43. Signature: hv1K5zudOMTonR742u0WCvhWEVk=


阿里云工程师从昨天下午一直在排查,到现在要我提供小程序里使用image标签 访问图片的响应消息头,我也不知道如何提供,问题还在搁置,请各位施以援手,谢谢

回答关注问题邀请回答
收藏

1 个回答

  • 汪育宏
    汪育宏
    12-18

    时至今日,我还存在同样的问题

    12-18
    有用
    回复
登录 后发表内容