我尝试使用PreBid on AMP pages,但我的remote.html文件遇到了跨域框架问题:
我使用Amazon S3托管了我的remote.html文件并更新了CORS配置以允许我的域名。但我的浏览器中仍然出现以下错误。
Blocked a frame with origin "https://s3.amazonaws.com" from accessing a cross-origin frame. Error: Blocked a frame with origin "https://s3.amazonaws.com" from accessing a cross-origin frame.
at Zc (https://3p.ampproject.net/1504040004635/f.js:82:23)
at HTMLIFrameElement.<anonymous>
(https://3p.ampproject.net/1504040004635/f.js:81:346)
我的S3存储桶的我的CORS配置文件如下:
<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>https://3p.ampproject.net</AllowedOrigin>
<AllowedMethod>PUT</AllowedMethod>
<AllowedMethod>POST</AllowedMethod>
<AllowedMethod>DELETE</AllowedMethod>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<AllowedHeader>Authorization</AllowedHeader>
</CORSRule>
<CORSRule>
<AllowedOrigin><http://my_domain_name.com></AllowedOrigin>
<AllowedMethod>PUT</AllowedMethod>
<AllowedMethod>POST</AllowedMethod>
<AllowedMethod>DELETE</AllowedMethod>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<AllowedHeader>Authorization</AllowedHeader>
</CORSRule>
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
</CORSRule>
</CORSConfiguration>
有关如何解决此问题的任何想法?
提前感谢。