Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
136
rated 0 times [  142] [ 6]  / answers: 1 / hits: 64642  / 15 Years ago, mon, october 19, 2009, 12:00:00

I need to upload the canvas image data to the server (database) on the fly, i.e., I need to create a form and with an input=file, and post the image data without any user interaction.


More From » html

 Answers
53

You don't need a file input, just get the data with ctx.getImageData() and post it to the server with Ajax.



See the MDN Documentation for CanvasRenderingContext2D.getImageData().



But you won't be able to get the image data in IE, even with ExCanvas.


[#98485] Wednesday, October 14, 2009, 15 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
diontajm

Total Points: 391
Total Questions: 104
Total Answers: 104

Location: Netherlands
Member since Mon, Jun 7, 2021
3 Years ago
;