It is rather dependent on the browser though, since the <canvas> element is not (natively) supported in Internet Explorer, and probably not in most older web browsers. Another, possibly easier, solution is to simply use a proxy for the image, and cache the image at server side.
Simon
I only need it to work in firefox, i tried the code but i keep ending up whit a image whit the right dimention, but its all transparant.
Its a png file, and what i could read, png is the ones that work best whit canvas.
Any ide how i can stop it from getting a transparant picture?
As that code is most likely working in the general case, you need to post some of the code you are using, and also the png image you are not able to read.
Simon
Postat av Simon (213.89.66.60) den 29 December, 2009 kl 21:15:28.
Som svar på: Re: Copy imagedata from img-tag postat av Puggan den 28 December, 2009 kl 15:24:13.