解决图片跨域

问题:下载图片 使用a标签的download 点击之后 跳转新页面 打开了预览图片

hack:

 

失败:

Origin 'http://localhost:9527' is therefore not allowed access.
has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:9527' is therefore not allowed access.

 

成功:

 

posted @ 2018-09-27 16:46  三行代码  阅读(2006)  评论(0编辑  收藏  举报