Cross-origin Image Load Denied By Cross-origin Resource Sharing Policy
I use html2canvas (from html2canvas.hertzen.com) to capture screenshot. I got this strange error like this: The code of my webpage is put on one host, say Host A. If my webpage c
Solution 1:
If you wish to load cross-origin images to a canvas, you need to either serve the image with cross-origin headers or under the same origin. That image under Facebook is served with the following header option set:
Access-Control-Allow-Origin:*
Meaning, it can be cross-origin loaded with the useCORS
option. However, it would appear that your Host B isn't serving them with cross-origin headers set.
Post a Comment for "Cross-origin Image Load Denied By Cross-origin Resource Sharing Policy"