2 ms·
Instead of doing $.get([remoteScript]), you inject img tags that point to prebuilt PNGs on a different server and decode them after they load. I could be wrong
by long 12y ago
Instead of doing $.get([remoteScript]), you inject img tags that point to prebuilt PNGs on a different server and decode them after they load.
I could be wrong, but doesn't that work?
- lawl 12y agoIt doesn't. You can load the img tag, but the browser will not let you access the image itself from javascript, unless you have the proper CORS headers.
- bshimmin 12y agoQuite right - it will complain that the canvas is "tainted" and won't let you do useful things like calling `getImageData`.
- long 12y agoAh -- useful to know. Thanks for the corrections, folks.
- iso8859-1 12y agoimgur allows any origin
- lawl 12y agoThey ask the server to fetch this URL. The client doesn't upload it.
- deleted 12y ago[deleted]